ci: parallelize rust tests, dedupe typecheck/clippy/sentry across workflows#895
Conversation
- Split `rust-tests` into `rust-core-tests` + `rust-tauri-tests` so they run in parallel (separate Swatinem cache keys; CEF cache only on the Tauri job). Clippy removed — `typecheck.yml` already runs it. - Drop Sentry debug-symbol upload from `build.yml`; release workflows already upload symbols, and `build.yml` strips debug info anyway. Also removes the now-unused `actions: read` permission. - Skip `tsc` inside `cargo tauri build` on `build.yml` by overriding `beforeBuildCommand` via `TAURI_CONFIG_OVERRIDE`. Typechecking stays in `typecheck.yml`; `package.json` is unchanged so local + release builds keep running `tsc`.
… on release - Add `@radix-ui/react-dialog`, `cmdk`, `@testing-library/user-event` — imported by `src/components/commands/*` but never actually installed, so `tsc` in the pre-push hook fails on a clean checkout. - Wire `scripts/upload_sentry_symbols.sh` into `release.yml` after the Tauri build. Release builds now upload Rust debug symbols (core sidecar + Tauri shell) to Sentry so production stack traces symbolicate. Gated on `release_enabled` and `SENTRY_AUTH_TOKEN`.
📝 WalkthroughWalkthroughCI workflows updated: TypeScript and test jobs switch to pnpm; Rust tests split into core and Tauri jobs with separate caches; Tauri build now injects Node build and staging commands via Changes
Sequence Diagram(s)sequenceDiagram
autonumber
rect rgba(135,206,250,0.5)
actor GitHubActions as "GitHub Actions (release job)"
end
rect rgba(152,251,152,0.5)
participant FS as "Repository FS (target/.../release/deps)"
end
rect rgba(255,182,193,0.5)
participant Script as "scripts/upload_sentry_symbols.sh"
end
rect rgba(255,228,181,0.5)
participant Sentry as "Sentry (org/project)"
end
GitHubActions->>FS: for each target deps dir (if exists)
FS-->>GitHubActions: directory present
GitHubActions->>Script: invoke upload script (env: SENTRY_* + VERSION + MATRIX_TARGET)
Script->>Sentry: upload debug symbols
Sentry-->>Script: ack
Script-->>GitHubActions: exit status
Estimated Code Review Effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly Related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
.github/workflows/test.yml (1)
106-161:⚠️ Potential issue | 🟡 MinorLGTM! Tauri tests properly parallelized with CEF caching.
The
rust-tauri-testsjob correctly:
- Maintains both workspace caches with distinct
taurikey- Includes CEF binary cache to avoid ~400MB downloads per run
- Uses inline sidecar staging appropriate for the test context
- Tests the Tauri shell independently from core
One note: The sidecar staging (lines 154–158) uses inline shell commands rather than
npm run core:stage. This is intentional and correct since the test environment doesn't require the full Node/npm setup, and the inline approach is simpler for CI.Note on Rust quality checks: The
typecheck.ymlworkflow includescargo fmt --all -- --checkfor all workspaces andcargo clippyfor the core crate. However,app/src-tauri/Cargo.tomlis not explicitly checked with clippy (the-p openhumanflag scopes the check to core only). Consider expanding clippy to include the Tauri shell as well.🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In @.github/workflows/test.yml around lines 106 - 161, The workflow's Rust lint step currently runs "cargo clippy" scoped to the core crate via the "-p openhuman" flag, so the Tauri shell crate (app/src-tauri) is not linted; update the typecheck workflow's clippy invocation to include the Tauri crate as well—either run clippy for the whole workspace (cargo clippy --workspace) or add the Tauri package to the flags (e.g., cargo clippy -p openhuman -p <tauri-crate-name>) or run cargo clippy with --manifest-path app/src-tauri/Cargo.toml to ensure the shell crate is checked.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Outside diff comments:
In @.github/workflows/test.yml:
- Around line 106-161: The workflow's Rust lint step currently runs "cargo
clippy" scoped to the core crate via the "-p openhuman" flag, so the Tauri shell
crate (app/src-tauri) is not linted; update the typecheck workflow's clippy
invocation to include the Tauri crate as well—either run clippy for the whole
workspace (cargo clippy --workspace) or add the Tauri package to the flags
(e.g., cargo clippy -p openhuman -p <tauri-crate-name>) or run cargo clippy with
--manifest-path app/src-tauri/Cargo.toml to ensure the shell crate is checked.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 1f4a3a28-16de-4bf0-92b0-5569df69cdd8
⛔ Files ignored due to path filters (1)
yarn.lockis excluded by!**/yarn.lock,!**/*.lock
📒 Files selected for processing (4)
.github/workflows/build.yml.github/workflows/release.yml.github/workflows/test.ymlapp/package.json
…sts-skip-typecheck
Upstream merged the pnpm migration (tinyhumansai#886) and the CEF deb runtime spec (tinyhumansai#893). After resolving conflicts: - Drop unused `waitForText` import and escape-`/` in the runtime spec so eslint passes on the hook's default rules. - Re-run `pnpm install` to refresh the root lockfile with the command-palette deps already declared in `app/package.json`.
- Updated GitHub Actions workflows for testing and type checking to use pnpm instead of yarn. - Removed caching steps related to yarn and adjusted dependency installation commands accordingly. - Ensured compatibility with Node.js 24.x and streamlined the setup process for pnpm.
There was a problem hiding this comment.
🧹 Nitpick comments (1)
.github/workflows/typecheck.yml (1)
64-67: Extend clippy coverage to Tauri shell crate.Currently clippy only runs on the core crate (
-p openhuman). Based on learnings emphasizing Rust checks on both repo root andapp/src-tauri/Cargo.toml, consider adding clippy for the Tauri shell:Suggested change
- name: Run clippy (core crate) run: cargo clippy -p openhuman +- name: Run clippy (Tauri shell) + run: cargo clippy --manifest-path app/src-tauri/Cargo.toml🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In @.github/workflows/typecheck.yml around lines 64 - 67, Currently the workflow only runs clippy for the core crate ("Run clippy (core crate)"); add a new step (e.g., "Run clippy (tauri crate)") that invokes cargo clippy against the Tauri shell's manifest (use --manifest-path pointing at app/src-tauri/Cargo.toml) so the Tauri crate is linted as well; insert this step alongside the existing cargo fmt and core clippy steps to ensure both crates are checked.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In @.github/workflows/typecheck.yml:
- Around line 64-67: Currently the workflow only runs clippy for the core crate
("Run clippy (core crate)"); add a new step (e.g., "Run clippy (tauri crate)")
that invokes cargo clippy against the Tauri shell's manifest (use
--manifest-path pointing at app/src-tauri/Cargo.toml) so the Tauri crate is
linted as well; insert this step alongside the existing cargo fmt and core
clippy steps to ensure both crates are checked.
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: fb78d4b9-9316-4df3-806c-2ef20dda7acd
⛔ Files ignored due to path filters (3)
app/yarn.lockis excluded by!**/yarn.lock,!**/*.lockpnpm-lock.yamlis excluded by!**/pnpm-lock.yamlyarn.lockis excluded by!**/yarn.lock,!**/*.lock
📒 Files selected for processing (6)
.github/workflows/build.yml.github/workflows/release.yml.github/workflows/test.yml.github/workflows/typecheck.ymlapp/package.jsonapp/test/e2e/specs/linux-cef-deb-runtime.spec.ts
✅ Files skipped from review due to trivial changes (2)
- app/package.json
- .github/workflows/build.yml
Summary
Clean up CI so dedicated workflows own each concern and PR/
mainbuilds stop doing duplicated work.test.yml— split the Rust job into two parallel jobs:rust-core-tests(fmt +cargo test -p openhuman) andrust-tauri-tests(sidecar build + stage +cargo testonapp/src-tauri). Separate Swatinem cache keys; CEF cache only on the Tauri job. Clippy removed from both —typecheck.yml'srust-qualityjob already runs it.build.yml— drop the inline Sentry debug-symbol upload. Release workflows now own symbol uploads, and this job stripped debug info anyway. Dropped the now-unusedactions: readpermission. Also skiptscinsidecargo tauri buildby overridingbeforeBuildCommandviaTAURI_CONFIG_OVERRIDE— typechecking stays intypecheck.yml.package.jsonunchanged, so local dev andrelease.ymlkeep runningtsc.release.yml— wirescripts/upload_sentry_symbols.shin after the Tauri build so production Rust stack traces (core sidecar + Tauri shell) symbolicate in Sentry. Gated onrelease_enabledandSENTRY_AUTH_TOKEN.app/package.json+yarn.lock— add@radix-ui/react-dialog,cmdk,@testing-library/user-event. These were imported undersrc/components/commands/but never actually installed, sotscfails on a clean checkout.Test plan
rust-core-testsandrust-tauri-testsrun in parallel and both green.build.ymlsucceeds without tsc and without the Sentry step.typecheck.ymlstill runs fmt + clippy + tsc.openhuman@<version>release.yarn dev,yarn build,cargo tauri buildstill work (unchangedpackage.jsonscripts).Summary by CodeRabbit
Chores
Bug Fixes
Tests