Commit Graph

307 Commits

Author SHA1 Message Date
Shaun Arman
bc50a78db7 fix: correct WIQL syntax and escape_wiql implementation
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 10s
Test / frontend-typecheck (pull_request) Successful in 1m11s
Test / frontend-tests (pull_request) Successful in 1m12s
PR Review Automation / review (pull_request) Successful in 3m6s
Test / rust-clippy (pull_request) Successful in 3m49s
Test / rust-tests (pull_request) Successful in 5m4s
- Replace CONTAINS with ~ operator (correct WIQL syntax for text matching)
- Remove escaping of ~, *, ? which are valid WIQL wildcards
- Update tests to reflect correct escape_wiql behavior
2026-04-14 20:38:21 -05:00
Shaun Arman
e6d1965342 security: address all issues from automated PR review
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 10s
Test / frontend-typecheck (pull_request) Successful in 1m9s
Test / frontend-tests (pull_request) Successful in 1m13s
PR Review Automation / review (pull_request) Successful in 2m58s
Test / rust-clippy (pull_request) Successful in 3m50s
Test / rust-tests (pull_request) Successful in 5m12s
- Add missing CQL escaping for &, |, +, - characters
- Improve escape_wiql() to escape more dangerous characters: ", \, (, ), ~, *, ?, ;, =
- Sanitize HTML in excerpts using strip_html_tags() to prevent XSS
- Add unit tests for escape_wiql, escape_cql, canonicalize_url functions
- Document expand_query() behavior (always returns at least original query)
- All tests pass (158/158), cargo fmt and clippy pass
2026-04-14 20:26:05 -05:00
Shaun Arman
708e1e9c18 security: fix query expansion issues from PR review
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 12s
Test / frontend-typecheck (pull_request) Successful in 1m11s
Test / frontend-tests (pull_request) Successful in 1m16s
PR Review Automation / review (pull_request) Successful in 3m0s
Test / rust-clippy (pull_request) Successful in 3m50s
Test / rust-tests (pull_request) Successful in 5m0s
- Use MAX_EXPANDED_QUERIES constant in confluence_search.rs instead of hardcoded 3
- Improve escape_wiql() to escape more dangerous characters: ", \, (, ), ~, *, ?, ;, =
- Fix logging to show expanded_query instead of search_url in confluence_search.rs

All tests pass (142/142), cargo fmt and clippy pass.
2026-04-14 20:07:59 -05:00
Shaun Arman
5b45c6c418 fix(integrations): security and correctness improvements
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 12s
Test / frontend-typecheck (pull_request) Successful in 1m18s
Test / frontend-tests (pull_request) Successful in 1m21s
Test / rust-clippy (pull_request) Successful in 3m56s
PR Review Automation / review (pull_request) Successful in 4m20s
Test / rust-tests (pull_request) Successful in 5m22s
- Add url canonicalization for deduplication (strip fragments/query params)
- Add WIQL injection escaping for Azure DevOps work item searches
- Add CQL injection escaping for Confluence searches
- Add MAX_EXPANDED_QUERIES constant for consistency
- Fix logging to show expanded_query instead of search_url
- Add input validation for empty queries
- Add url crate dependency for URL parsing

All 142 tests pass.
2026-04-14 19:55:32 -05:00
Shaun Arman
096068ed2b feat(integrations): implement query expansion for semantic search
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 12s
Test / frontend-typecheck (pull_request) Successful in 1m11s
Test / frontend-tests (pull_request) Successful in 1m15s
PR Review Automation / review (pull_request) Successful in 3m13s
Test / rust-clippy (pull_request) Successful in 3m45s
Test / rust-tests (pull_request) Successful in 5m9s
- Add query_expansion.rs module with product synonyms and keyword extraction
- Update confluence_search.rs to use expanded queries
- Update servicenow_search.rs to use expanded queries
- Update azuredevops_search.rs to use expanded queries
- Update webview_fetch.rs to use expanded queries
- Fix extract_keywords infinite loop bug for non-alphanumeric endings

All 142 tests pass.
2026-04-14 19:37:27 -05:00
cdb1dd1dad chore: update CHANGELOG.md for v0.2.55 [skip ci] 2026-04-13 21:09:47 +00:00
6dbe40ef03 chore: update CHANGELOG.md for v0.2.53 [skip ci] 2026-04-13 20:25:56 +00:00
Shaun Arman
75fc3ca67c fix: add Windows nsis target and update CHANGELOG to v0.2.61
All checks were successful
Auto Tag / autotag (push) Successful in 6s
Auto Tag / wiki-sync (push) Successful in 6s
Auto Tag / changelog (push) Successful in 43s
Auto Tag / build-macos-arm64 (push) Successful in 3m0s
Auto Tag / build-linux-amd64 (push) Successful in 11m29s
Auto Tag / build-linux-arm64 (push) Successful in 13m31s
Auto Tag / build-windows-amd64 (push) Successful in 14m10s
- Update CHANGELOG to include releases v0.2.54 through v0.2.61
- Add 'nsis' to bundle targets in tauri.conf.json for Windows builds
- This fixes Windows artifact upload failures by enabling .exe/.msi generation

The Windows build was failing because tauri.conf.json only had Linux bundle
targets (['deb', 'rpm']). Without nsis target, no Windows installers were
produced, causing the upload step to fail with 'No Windows amd64 artifacts
were found'.
2026-04-13 15:25:05 -05:00
fdae6d6e6d chore: update CHANGELOG.md for v0.2.53 [skip ci] 2026-04-13 19:58:25 +00:00
Shaun Arman
d78181e8c0 chore: trigger release with fix
Some checks failed
Auto Tag / autotag (push) Successful in 7s
Auto Tag / wiki-sync (push) Successful in 6s
Auto Tag / changelog (push) Successful in 43s
Auto Tag / build-macos-arm64 (push) Successful in 4m25s
Auto Tag / build-linux-amd64 (push) Successful in 11m27s
Auto Tag / build-linux-arm64 (push) Successful in 13m25s
Auto Tag / build-windows-amd64 (push) Failing after 13m38s
2026-04-13 14:57:35 -05:00
Shaun Arman
b4ff52108a fix: remove AppImage from upload artifact patterns
Some checks failed
Auto Tag / autotag (push) Successful in 6s
Auto Tag / wiki-sync (push) Successful in 6s
Auto Tag / changelog (push) Has been cancelled
Auto Tag / build-linux-arm64 (push) Has been cancelled
Auto Tag / build-windows-amd64 (push) Has been cancelled
Auto Tag / build-macos-arm64 (push) Has been cancelled
Auto Tag / build-linux-amd64 (push) Has been cancelled
2026-04-13 14:57:14 -05:00
29a68c07e9 chore: update CHANGELOG.md for v0.2.53 [skip ci] 2026-04-13 18:43:07 +00:00
Shaun Arman
40a2c25428 chore: trigger changelog update for AppImage removal
Some checks failed
Auto Tag / autotag (push) Successful in 9s
Auto Tag / wiki-sync (push) Successful in 8s
Auto Tag / changelog (push) Successful in 44s
Auto Tag / build-macos-arm64 (push) Successful in 3m8s
Auto Tag / build-linux-amd64 (push) Successful in 11m29s
Auto Tag / build-linux-arm64 (push) Successful in 13m28s
Auto Tag / build-windows-amd64 (push) Failing after 7m46s
2026-04-13 13:42:15 -05:00
Shaun Arman
62e3570a15 fix: remove AppImage bundling to fix linux-amd64 build
Some checks failed
Auto Tag / autotag (push) Successful in 6s
Auto Tag / wiki-sync (push) Successful in 6s
Build CI Docker Images / windows-cross (push) Successful in 7s
Build CI Docker Images / linux-arm64 (push) Successful in 6s
Auto Tag / changelog (push) Has been cancelled
Auto Tag / build-windows-amd64 (push) Has been cancelled
Auto Tag / build-linux-amd64 (push) Has been cancelled
Auto Tag / build-macos-arm64 (push) Has been cancelled
Auto Tag / build-linux-arm64 (push) Has been cancelled
Build CI Docker Images / linux-amd64 (push) Successful in 2m37s
- Remove appimage from bundle targets in tauri.conf.json
- Remove linuxdeploy from Dockerfile
- Update Dockerfile to remove fuse dependency (not needed)
2026-04-13 13:41:56 -05:00
41e5753de6 chore: update CHANGELOG.md for v0.2.53 [skip ci] 2026-04-13 18:18:07 +00:00
Shaun Arman
25201eaac1 chore: trigger changelog update for latest fixes
Some checks failed
Auto Tag / autotag (push) Successful in 5s
Auto Tag / wiki-sync (push) Successful in 5s
Auto Tag / changelog (push) Successful in 1m37s
Auto Tag / build-macos-arm64 (push) Successful in 2m21s
Auto Tag / build-linux-amd64 (push) Failing after 13m17s
Auto Tag / build-windows-amd64 (push) Successful in 15m20s
Auto Tag / build-linux-arm64 (push) Successful in 13m46s
2026-04-13 13:16:23 -05:00
618eb6b43d chore: update CHANGELOG.md for v0.2.53 [skip ci] 2026-04-13 18:07:19 +00:00
Shaun Arman
5084dca5e3 fix: add fuse dependency for AppImage support
Some checks failed
Auto Tag / autotag (push) Successful in 6s
Auto Tag / wiki-sync (push) Successful in 5s
Build CI Docker Images / windows-cross (push) Successful in 6s
Build CI Docker Images / linux-arm64 (push) Successful in 6s
Auto Tag / changelog (push) Successful in 37s
Build CI Docker Images / linux-amd64 (push) Successful in 1m56s
Auto Tag / build-macos-arm64 (push) Successful in 2m27s
Auto Tag / build-linux-amd64 (push) Has been cancelled
Auto Tag / build-windows-amd64 (push) Has been cancelled
Auto Tag / build-linux-arm64 (push) Has been cancelled
2026-04-13 13:06:33 -05:00
Shaun Arman
6cbdcaed21 refactor: revert to original Dockerfile without manual linuxdeploy installation
- CI handles linuxdeploy download and execution via npx tauri build
2026-04-13 13:06:33 -05:00
Shaun Arman
8298506435 refactor: remove custom linuxdeploy install per CI CI uses tauri-downloaded version 2026-04-13 13:06:33 -05:00
412c5e70f0 chore: update CHANGELOG.md for v0.2.53 [skip ci] 2026-04-13 17:01:51 +00:00
05f87a7bff Merge pull request 'fix: add missing ai_providers columns and fix linux-amd64 build' (#41) from fix/ai-provider-migration-issue into master
Some checks failed
Auto Tag / autotag (push) Successful in 14s
Auto Tag / wiki-sync (push) Successful in 14s
Build CI Docker Images / windows-cross (push) Successful in 11s
Build CI Docker Images / linux-arm64 (push) Successful in 10s
Auto Tag / changelog (push) Successful in 54s
Auto Tag / build-macos-arm64 (push) Successful in 2m57s
Auto Tag / build-linux-amd64 (push) Failing after 13m36s
Auto Tag / build-linux-arm64 (push) Successful in 15m7s
Auto Tag / build-windows-amd64 (push) Successful in 15m35s
Build CI Docker Images / linux-amd64 (push) Failing after 7s
Reviewed-on: #41
2026-04-13 17:00:50 +00:00
Shaun Arman
8e1d43da43 fix: address critical AI review issues
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 28s
Test / frontend-typecheck (pull_request) Successful in 1m29s
Test / frontend-tests (pull_request) Successful in 1m31s
PR Review Automation / review (pull_request) Successful in 3m28s
Test / rust-clippy (pull_request) Successful in 4m29s
Test / rust-tests (pull_request) Successful in 5m42s
- Fix linuxdeploy AppImage extraction using --appimage-extract
- Remove 'has no column named' from duplicate column error handling
- Use strftime instead of datetime for created_at default format
2026-04-13 08:50:34 -05:00
Shaun Arman
2d7aac8413 fix: address AI review findings
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 15s
Test / frontend-typecheck (pull_request) Successful in 1m21s
Test / frontend-tests (pull_request) Successful in 1m25s
PR Review Automation / review (pull_request) Successful in 3m32s
Test / rust-clippy (pull_request) Successful in 4m1s
Test / rust-tests (pull_request) Successful in 5m18s
- Add -L flag to curl for linuxdeploy redirects
- Split migration 015 into 015_add_use_datastore_upload and 016_add_created_at
- Use separate execute calls for ALTER TABLE statements
- Add idempotency test for migration 015
- Use bool type for use_datastore_upload instead of i64
2026-04-13 08:38:43 -05:00
Shaun Arman
84c69fbea8 fix: add missing ai_providers columns and fix linux-amd64 build
Some checks failed
Test / rust-fmt-check (pull_request) Successful in 15s
Test / rust-clippy (pull_request) Failing after 17s
Test / frontend-typecheck (pull_request) Successful in 1m23s
Test / frontend-tests (pull_request) Successful in 1m23s
PR Review Automation / review (pull_request) Successful in 3m16s
Test / rust-tests (pull_request) Successful in 4m19s
- Add migration 015 to add use_datastore_upload and created_at columns
- Handle column-already-exists errors gracefully
- Update Dockerfile to install linuxdeploy for AppImage bundling
- Add fuse dependency for AppImage support
2026-04-13 08:22:08 -05:00
9bc570774a chore: update CHANGELOG.md for v0.2.53 [skip ci] 2026-04-13 03:19:05 +00:00
f7011c8837 Merge pull request 'fix(ci): use Gitea file API to push CHANGELOG.md' (#40) from fix/changelog-push into master
Some checks failed
Auto Tag / autotag (push) Successful in 7s
Auto Tag / wiki-sync (push) Successful in 5s
Auto Tag / changelog (push) Successful in 53s
Auto Tag / build-linux-arm64 (push) Successful in 14m55s
Auto Tag / build-windows-amd64 (push) Successful in 15m35s
Auto Tag / build-macos-arm64 (push) Successful in 10m26s
Auto Tag / build-linux-amd64 (push) Failing after 7m50s
Reviewed-on: #40
2026-04-13 03:18:10 +00:00
Shaun Arman
f74238a65a fix(ci): harden CHANGELOG.md API push step per review
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 26s
Test / frontend-typecheck (pull_request) Successful in 1m37s
Test / frontend-tests (pull_request) Successful in 1m25s
PR Review Automation / review (pull_request) Successful in 3m54s
Test / rust-clippy (pull_request) Successful in 4m25s
Test / rust-tests (pull_request) Successful in 5m47s
- set -euo pipefail (was -eu; pipefail catches silent pipe failures)
- Validate TAG against ^v[0-9]+\.[0-9]+\.[0-9]+$ before use in commit
  message and JSON payload — prevents shell injection
- Tolerate 404 on SHA fetch (new file): curl 2>/dev/null or true keeps
  CURRENT_SHA empty rather than causing jq to abort
- Use jq -n to build JSON payload — conditionally omits sha field when
  file does not exist yet; eliminates manual string escaping
- Check HTTP status of PUT; print response body and exit 1 on non-2xx
- Add Accept: application/json header to SHA fetch request
2026-04-12 22:13:25 -05:00
Shaun Arman
2da529fb75 fix(ci): use Gitea file API to push CHANGELOG.md — eliminates non-fast-forward rejection
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 14s
PR Review Automation / review (pull_request) Successful in 2m57s
Test / frontend-typecheck (pull_request) Successful in 1m15s
Test / frontend-tests (pull_request) Successful in 1m18s
Test / rust-clippy (pull_request) Successful in 5m34s
Test / rust-tests (pull_request) Successful in 6m52s
git push origin HEAD:master fails when master advances between the job's
fetch and its push. Replace with PUT /repos/.../contents/CHANGELOG.md
which atomically updates the file on master regardless of HEAD position.
2026-04-12 22:06:21 -05:00
2f6d5c1865 Merge pull request 'fix(ci): correct git-cliff archive path in tar extraction' (#39) from feat/git-cliff-changelog into master
Some checks failed
Auto Tag / wiki-sync (push) Successful in 9s
Auto Tag / autotag (push) Successful in 12s
Auto Tag / changelog (push) Failing after 42s
Auto Tag / build-windows-amd64 (push) Has been cancelled
Auto Tag / build-linux-amd64 (push) Has been cancelled
Auto Tag / build-linux-arm64 (push) Has been cancelled
Auto Tag / build-macos-arm64 (push) Has been cancelled
Reviewed-on: #39
2026-04-13 03:03:26 +00:00
Shaun Arman
280a9f042e fix(ci): correct git-cliff archive path in tar extraction
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 18s
Test / frontend-typecheck (pull_request) Successful in 1m10s
Test / frontend-tests (pull_request) Successful in 1m20s
PR Review Automation / review (pull_request) Successful in 2m56s
Test / rust-clippy (pull_request) Successful in 5m4s
Test / rust-tests (pull_request) Successful in 7m5s
2026-04-12 21:59:30 -05:00
41bc5f38ff Merge pull request 'feat(ci): automated changelog generation via git-cliff' (#38) from feat/git-cliff-changelog into master
Some checks failed
Auto Tag / autotag (push) Successful in 6s
Auto Tag / wiki-sync (push) Successful in 7s
Auto Tag / build-windows-amd64 (push) Failing after 16s
Auto Tag / changelog (push) Failing after 39s
Auto Tag / build-macos-arm64 (push) Successful in 2m4s
Auto Tag / build-linux-amd64 (push) Has been cancelled
Auto Tag / build-linux-arm64 (push) Has been cancelled
Reviewed-on: #38
2026-04-13 02:56:50 +00:00
Shaun Arman
6d2b69ffb0 feat(ci): add automated changelog generation via git-cliff
- Add cliff.toml with Tera template: feat/fix/perf/docs/refactor included;
  ci/chore/build/test/style excluded
- Bootstrap CHANGELOG.md from all existing semver tags (v0.1.0–v0.2.49)
- Add changelog job to auto-tag.yml: runs after autotag in parallel with
  build jobs; installs git-cliff v2.7.0 musl binary, generates CHANGELOG.md,
  PATCHes Gitea release body with per-release notes, commits CHANGELOG.md
  to master with [skip ci] to prevent re-trigger, uploads as release asset
- Add set -eu to all changelog job steps
- Null-check RELEASE_ID before API calls; create release if missing
  (race-condition fix: changelog finishes before build jobs create release)
- Add Changelog Generation section to docs/wiki/CICD-Pipeline.md
2026-04-12 21:56:16 -05:00
eae1c6e8b7 Merge pull request 'fix(ci): add APPIMAGE_EXTRACT_AND_RUN to build-linux-amd64' (#37) from fix/appimage-extract-and-run into master
Some checks failed
Auto Tag / autotag (push) Successful in 6s
Auto Tag / wiki-sync (push) Successful in 6s
Auto Tag / build-macos-arm64 (push) Successful in 2m11s
Auto Tag / build-linux-arm64 (push) Successful in 15m4s
Auto Tag / build-windows-amd64 (push) Successful in 16m30s
Auto Tag / build-linux-amd64 (push) Failing after 8m1s
Reviewed-on: #37
2026-04-13 02:16:44 +00:00
Shaun Arman
27a46a7542 fix(ci): add APPIMAGE_EXTRACT_AND_RUN to build-linux-amd64
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 13s
Test / rust-clippy (pull_request) Successful in 3m47s
PR Review Automation / review (pull_request) Successful in 4m11s
Test / frontend-typecheck (pull_request) Successful in 1m36s
Test / frontend-tests (pull_request) Successful in 1m26s
Test / rust-tests (pull_request) Successful in 5m30s
linuxdeploy is itself an AppImage. Running it inside a Docker container
requires APPIMAGE_EXTRACT_AND_RUN=1 so it extracts and runs its payload
directly rather than relying on FUSE (unavailable in containers).
Already set on build-linux-arm64 — missing from the amd64 job.
2026-04-12 20:56:42 -05:00
21de93174c Merge pull request 'perf(ci): pre-baked images + cargo/npm caching (~70% faster builds)' (#36) from feat/pr-review-workflow into master
Some checks failed
Auto Tag / autotag (push) Successful in 7s
Auto Tag / wiki-sync (push) Successful in 8s
Auto Tag / build-linux-arm64 (push) Successful in 15m53s
Auto Tag / build-windows-amd64 (push) Successful in 16m34s
Auto Tag / build-linux-amd64 (push) Failing after 8m10s
Auto Tag / build-macos-arm64 (push) Failing after 12m41s
Build CI Docker Images / windows-cross (push) Successful in 12m1s
Build CI Docker Images / linux-amd64 (push) Successful in 18m52s
Build CI Docker Images / linux-arm64 (push) Successful in 19m50s
Reviewed-on: #36
2026-04-13 01:23:48 +00:00
Shaun Arman
a365cba30e fix(ci): address second AI review — || true, ca-certs, cache@v4, key suffixes
All checks were successful
Test / rust-fmt-check (pull_request) Successful in 13s
Test / frontend-typecheck (pull_request) Successful in 1m17s
Test / frontend-tests (pull_request) Successful in 1m20s
PR Review Automation / review (pull_request) Successful in 3m47s
Test / rust-clippy (pull_request) Successful in 4m4s
Test / rust-tests (pull_request) Successful in 5m21s
Dockerfiles:
- Remove || true from rustup component add in all three Linux images;
  rust:1.88-slim default profile already includes both components so the
  command is a clean no-op, not a failure risk — silencing errors served
  no purpose and only hid potential toolchain issues
- Add ca-certificates explicitly to Dockerfile.linux-amd64 and
  Dockerfile.windows-cross (rust:1.88-slim includes it, but being
  explicit is consistent with the arm64 fix and future-proofs against
  base image changes)

Workflows:
- Upgrade actions/cache@v3 → @v4 across test.yml and auto-tag.yml
  (v3 deprecated; v4 has parallel uploads and better large-cache support)
- Add linux-amd64 suffix to cargo cache keys in test.yml Rust jobs and
  auto-tag.yml build-linux-amd64 job; all four jobs target the same
  architecture and now share a cache, benefiting from cross-job hits
  (registry cache is source tarballs, not compiled artifacts — no
  pollution risk between targets)

Not changed:
- alpine:latest + docker-cli in build-images.yml is correct; the reviewer
  confused DinD with socket passthrough — docker:24-cli also has no daemon,
  both use the host socket; the builds already proved alpine works
- curl|bash for rustup is the official install method; rustup.rs publishes
  no checksums for the installer script itself
2026-04-12 20:16:32 -05:00
Shaun Arman
2ce38b9477 fix(ci): resolve test.yml failures — Cargo.lock, updated test assertions
Cargo.lock:
- Commit the pre-existing version bump (0.1.0 → 0.2.50) so cargo
  --locked does not fail in CI; Cargo.toml already at 0.2.50

releaseWorkflowCrossPlatformArtifacts.test.ts:
- Update test that previously checked for ubuntu:22.04 / ports mirror
  inline in auto-tag.yml; that setup moved to the pre-baked
  trcaa-linux-arm64 image so the test now verifies the image reference
  and cross-compile env vars instead

ciDockerBuilders.test.ts:
- Update test that checked for docker:24-cli; changed to alpine:latest
  + docker-cli to avoid act_runner v0.3.1 duplicate socket mount bug;
  negative assertion on docker:24-cli retained
2026-04-12 20:16:32 -05:00
Shaun Arman
461959fbca fix(docker): add ca-certificates to arm64 base image step 1
ubuntu:22.04 minimal does not guarantee ca-certificates is present
before the multiarch apt operations in Step 2. curl in Step 3 then
fails with error 77 (CURLE_SSL_CACERT_BADFILE) when fetching the
nodesource setup script over HTTPS.
2026-04-12 20:16:32 -05:00
Shaun Arman
a86ae81161 docs(docker): expand rebuild trigger comments to include OpenSSL and Tauri CLI 2026-04-12 20:16:32 -05:00
Shaun Arman
decd1fe5cf fix(ci): replace docker:24-cli with alpine + docker-cli in build-images
act_runner v0.3.1 has special-case handling for images named docker:*:
it automatically adds /var/run/docker.sock to the container's bind
mounts. The runner's own global config already mounts the socket, so
the two entries collide and the container fails to start with
"Duplicate mount point: /var/run/docker.sock".

Fix: use alpine:latest (no special handling) and install docker-cli
via apk alongside git in each Checkout step. The docker socket is
still available via the runner's global bind — we just stop triggering
the duplicate.
2026-04-12 20:16:32 -05:00
Shaun Arman
16930dca70 fix(ci): address AI review — rustup idempotency and cargo --locked
Dockerfiles:
- Merge rustup target add and component add into one chained RUN with
  || true guard, making it safe if rustfmt/clippy are already present
  in the base image's default toolchain profile (rust:1.88-slim default
  profile includes both; the guard is belt-and-suspenders)

test.yml:
- Add --locked to cargo clippy and cargo test to enforce Cargo.lock
  during CI, preventing silent dependency upgrades

Not addressed (accepted/out of scope):
- git in images: already installed in all three Dockerfiles (lines 19,
  13, 15 respectively) — reviewer finding was incorrect
- HTTP registry: accepted risk for air-gapped self-hosted infrastructure
- Image signing (Cosign): no infrastructure in place yet
- Hardcoded registry IP: consistent with project-wide pattern
2026-04-12 20:16:32 -05:00
Shaun Arman
bb0f3eceab perf(ci): use pre-baked images and add cargo/npm caching
Switch all test and release build jobs from raw base images to the
pre-baked images already defined in .docker/ and pushed to the local
Gitea registry. Add actions/cache@v3 for Cargo registry and npm to
eliminate redundant downloads on subsequent runs.

Changes:
- Dockerfile.linux-amd64/arm64: bake in rustfmt and clippy components
- test.yml: rust jobs → trcaa-linux-amd64:rust1.88-node22; drop inline
  apt-get and rustup component-add steps; add cargo cache
- test.yml: frontend jobs → add npm cache
- auto-tag.yml: build-linux-amd64 → trcaa-linux-amd64; drop Install
  dependencies step and rustup target add
- auto-tag.yml: build-windows-amd64 → trcaa-windows-cross; drop Install
  dependencies step and rustup target add
- auto-tag.yml: build-linux-arm64 → trcaa-linux-arm64 (ubuntu:22.04-based);
  drop ~40-line Install dependencies step, . "$HOME/.cargo/env", and
  rustup target add (all pre-baked in image ENV PATH)
- All build jobs: add cargo and npm cache steps
- docs/wiki/CICD-Pipeline.md: document pre-baked images, cache keys,
  and insecure-registries daemon prerequisite

Expected savings: ~70% faster PR test suite (~1.5 min vs ~5 min),
~72% faster release builds (~7 min vs ~25 min) after cache warms up.

NOTE: Trigger build-images.yml via workflow_dispatch before merging
to ensure images contain rustfmt/clippy before workflow changes land.
2026-04-12 20:16:32 -05:00
4fa01ae7ed Merge pull request 'feat/pr-review-workflow' (#35) from feat/pr-review-workflow into master
All checks were successful
Auto Tag / build-linux-amd64 (push) Successful in 35m33s
Auto Tag / build-linux-arm64 (push) Successful in 35m41s
Auto Tag / build-macos-arm64 (push) Successful in 18m31s
Auto Tag / autotag (push) Successful in 8s
Auto Tag / wiki-sync (push) Successful in 9s
Auto Tag / build-windows-amd64 (push) Successful in 14m12s
Reviewed-on: #35
2026-04-12 23:08:46 +00:00
Shaun Arman
181b9ef734 fix: harden pr-review workflow — secret redaction, log safety, auth header
All checks were successful
Test / frontend-typecheck (pull_request) Successful in 1m12s
Test / rust-tests (pull_request) Successful in 27m19s
Test / rust-fmt-check (pull_request) Successful in 2m35s
PR Review Automation / review (pull_request) Successful in 3m45s
Test / rust-clippy (pull_request) Successful in 25m55s
Test / frontend-tests (pull_request) Successful in 1m10s
- Replace flawed sed-based redaction with grep -v line-removal covering
  JS/YAML assignments, Authorization headers, AWS keys (AKIA…), Slack
  tokens (xox…), GitHub tokens (gh[opsu]_…), URLs with embedded
  credentials, and long Base64 strings
- Add -c flag to jq -n when building Ollama request body (compact JSON)
- Remove jq . full response dump to prevent LLM-echoed secrets in logs
- Change Gitea API Authorization header from `token` to `Bearer`
2026-04-12 18:03:17 -05:00
Shaun Arman
144a4551f2 fix: revert to two-dot diff — three-dot requires merge base unavailable in shallow clone
All checks were successful
PR Review Automation / review (pull_request) Successful in 3m46s
Test / rust-clippy (pull_request) Successful in 19m24s
Test / frontend-typecheck (pull_request) Successful in 1m15s
Test / rust-tests (pull_request) Successful in 20m43s
Test / frontend-tests (pull_request) Successful in 1m13s
Test / rust-fmt-check (pull_request) Successful in 2m46s
2026-04-12 17:40:12 -05:00
Shaun Arman
47b2e824e0 fix: replace github.server_url with hardcoded gogs.tftsr.com for container access 2026-04-12 17:40:12 -05:00
Shaun Arman
82aae00858 fix: resolve AI review false positives and address high/medium issues
Root cause of false-positive "critical" errors:
- sed pattern was matching api_key/token within YAML variable names
  (e.g. OLLAMA_API_KEY:) and redacting the ${{ secrets.X }} value,
  producing mangled syntax that confused the AI reviewer
- Fix: use [^$[:space:]] to skip values starting with $ (template
  expressions and shell variable references)

Other fixes:
- Replace --retry-all-errors with --retry-connrefused --retry-max-time 120
  to avoid wasting retries on unrecoverable 4xx errors
- Check HTTP_CODE before jq validation so error messages are meaningful
- Add permissions: pull-requests: write to job
- Add edited to pull_request.types so title changes trigger re-review
- Change git diff .. to git diff ... (three-dot merge-base diff)
- Replace hardcoded server/repo URLs with github.server_url and
  github.repository context variables (portability)
- Log review length before posting to detect truncation
2026-04-12 17:40:12 -05:00
Shaun Arman
1a4c6df6c9 fix: harden pr-review workflow — URLs, DNS, correctness and reliability
Security:
- Replace http://172.0.0.29:3000 git remote with https://gogs.tftsr.com
- Replace http://172.0.0.29:3000 Gitea API URL with https://gogs.tftsr.com
- Remove internal 172.0.0.29 from container DNS (keep 8.8.8.8, 1.1.1.1)
- Move PR_TITLE and PR_NUMBER to env vars to prevent shell injection

Correctness:
- Fix diff_size comparison from lexicographic > '0' to != '0'
- Strip leading whitespace from wc -l output via tr -d ' '
- Switch diff truncation from head -c 20000 to head -n 500 (line-safe)
- Add jq empty validation before parsing Ollama response

Reliability:
- Add --connect-timeout 30 and --retry 3 --retry-delay 5 to Ollama curl
- Add --connect-timeout 10 to review POST curl
- Change Post review comment to if: always() so it runs on analysis failure
- Post explicit failure comment when analysis produces no output
2026-04-12 17:40:12 -05:00
Shaun Arman
2d0f95e9db fix: configure container DNS to resolve ollama-ui.tftsr.com 2026-04-12 17:40:12 -05:00