Skip to content

fix(ci): build relay with optimized profile to fix flaky e2e tests#307

Merged
wesbillman merged 2 commits into
mainfrom
fix/ci-relay-optimized-build
Apr 13, 2026
Merged

fix(ci): build relay with optimized profile to fix flaky e2e tests#307
wesbillman merged 2 commits into
mainfrom
fix/ci-relay-optimized-build

Conversation

@wesbillman

Copy link
Copy Markdown
Collaborator

Summary

  • The integration e2e tests (stream.spec.ts) randomly fail because the relay is built with cargo build (debug mode), which produces a binary 10-30x slower than release
  • Under CI load, the unoptimized relay can't deliver messages between browser contexts fast enough, causing 15s delivery timeouts and relay unresponsiveness on retries
  • Adds a [profile.ci] Cargo profile (inherits release, no LTO) and uses it for the relay build in the desktop-e2e-integration job
  • Also caches the workspace-root target/ directory so the optimized relay build is incremental across CI runs

Test plan

  • CI integration tests pass (this PR is its own test — if the e2e suite goes green, the fix works)
  • Verify relay build step uses --profile ci and binary runs from target/ci/
  • Monitor for flaky stream.spec.ts failures over the next few CI runs

🤖 Generated with Claude Code

renovate Bot and others added 2 commits April 13, 2026 11:50
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
The integration e2e tests randomly fail because the relay is built in
debug mode (`cargo build`), making it 10-30x slower than a release
build.  Under CI load the unoptimised binary cannot route messages fast
enough, causing delivery timeouts and eventual relay unresponsiveness
on retries.

Add a `[profile.ci]` (inherits `release`, no LTO) and use it for the
relay build in the integration job.  Also cache the workspace-root
target directory so the optimised build is incremental across runs.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@wesbillman wesbillman merged commit 4c6c897 into main Apr 13, 2026
10 checks passed
@wesbillman wesbillman deleted the fix/ci-relay-optimized-build branch April 13, 2026 18:04
tellaho added a commit that referenced this pull request Apr 14, 2026
* origin/main:
  Replace inline channel creation with dialog (#312)
  chore: improve chat message layout to left-aligned design (#309)
  Add edit dialog for managed agents with relay profile sync (#277)
  fix(ci): build relay with optimized profile to fix flaky e2e tests (#307)
  Update actions/checkout action to v6 (#305)
  Update dependency @tanstack/react-query to v5.98.0 (#304)
  Update dependency @playwright/test to v1.59.1 (#303)
  Update react monorepo to v19.2.5 (#302)
  feat(mobile): scaffold Flutter app with Riverpod & Catppuccin theme (#306)
  Update dependency @tanstack/react-router to v1.168.13 (#301)
  feat: Markdown-based persona packs (crate + ACP + desktop) (#297)
  feat(desktop): improve Agents page UX (#298)
  feat(desktop): add Pulse social notes surface (#296)
  Fix flaky desktop smoke tests (#294)
  Add agent lifecycle controls to channel members sidebar (#291)

# Conflicts:
#	desktop/pnpm-lock.yaml
tlongwell-block added a commit that referenced this pull request Apr 14, 2026
* origin/main:
  feat(desktop): deterministic nested thread panels (#308)
  fix: show private channels in channel browser when user is a member (#311)
  Replace inline channel creation with dialog (#312)
  chore: improve chat message layout to left-aligned design (#309)
  Add edit dialog for managed agents with relay profile sync (#277)
  fix(ci): build relay with optimized profile to fix flaky e2e tests (#307)
  Update actions/checkout action to v6 (#305)
  Update dependency @tanstack/react-query to v5.98.0 (#304)
  Update dependency @playwright/test to v1.59.1 (#303)
  Update react monorepo to v19.2.5 (#302)
  feat(mobile): scaffold Flutter app with Riverpod & Catppuccin theme (#306)
  Update dependency @tanstack/react-router to v1.168.13 (#301)
  feat: Markdown-based persona packs (crate + ACP + desktop) (#297)
  feat(desktop): improve Agents page UX (#298)

# Conflicts:
#	desktop/scripts/check-file-sizes.mjs
#	desktop/src-tauri/Cargo.lock
#	desktop/src-tauri/Cargo.toml
wpfleger96 added a commit that referenced this pull request Jun 14, 2026
PR CI critical path: ~10m → ~8m target.

- Reduce `profile.ci` workspace opt-level to 1 (deps keep opt-level 3 via
  package."*" override so main-seeded dep caches stay valid). The 4m38s relay
  build should drop to ~2m15-2m45s. opt-1 keeps debug-assertions off (release
  inherit) so the PR #307 e2e flakiness fix holds.
- Add rui314/setup-mold to unit-tests, desktop-core, and desktop-e2e-relay
  (Linux link jobs only; not clippy/macOS/cross).
- Add concurrency group to ci.yml so superseded PR pushes cancel in-flight runs.
- Switch server-cross-compile to `cross check` on PRs, `cross build` on main.
  Catches compile/build-script errors on PRs; link-only errors surface on the
  main push which keeps full builds.
- Pin mobile job to flutter-version 3.41.7 (matches hermit) and enable caching.
- Add .cargo/config.toml with debug="line-tables-only" for local dev; applies
  to both the root and desktop/src-tauri workspaces via cargo config discovery.
- Add .vscode/settings.json with rust-analyzer.cargo.targetDir=true so RA
  checks land in target/rust-analyzer/ and stop invalidating cargo build cache.
- Remove rust-clippy and desktop-tauri-clippy from lefthook pre-push; CI
  rust-lint still gates merges. Saves 2-4m per push locally.
wpfleger96 added a commit that referenced this pull request Jun 16, 2026
PR CI critical path: ~10m → ~8m target.

- Reduce `profile.ci` workspace opt-level to 1 (deps keep opt-level 3 via
  package."*" override so main-seeded dep caches stay valid). The 4m38s relay
  build should drop to ~2m15-2m45s. opt-1 keeps debug-assertions off (release
  inherit) so the PR #307 e2e flakiness fix holds.
- Add rui314/setup-mold to unit-tests, desktop-core, and desktop-e2e-relay
  (Linux link jobs only; not clippy/macOS/cross).
- Add concurrency group to ci.yml so superseded PR pushes cancel in-flight runs.
- Switch server-cross-compile to `cross check` on PRs, `cross build` on main.
  Catches compile/build-script errors on PRs; link-only errors surface on the
  main push which keeps full builds.
- Pin mobile job to flutter-version 3.41.7 (matches hermit) and enable caching.
- Add .cargo/config.toml with debug="line-tables-only" for local dev; applies
  to both the root and desktop/src-tauri workspaces via cargo config discovery.
- Add .vscode/settings.json with rust-analyzer.cargo.targetDir=true so RA
  checks land in target/rust-analyzer/ and stop invalidating cargo build cache.
- Remove rust-clippy and desktop-tauri-clippy from lefthook pre-push; CI
  rust-lint still gates merges. Saves 2-4m per push locally.
wpfleger96 added a commit that referenced this pull request Jun 16, 2026
PR CI critical path: ~10m → ~8m target.

- Reduce `profile.ci` workspace opt-level to 1 (deps keep opt-level 3 via
  package."*" override so main-seeded dep caches stay valid). The 4m38s relay
  build should drop to ~2m15-2m45s. opt-1 keeps debug-assertions off (release
  inherit) so the PR #307 e2e flakiness fix holds.
- Add rui314/setup-mold to unit-tests, desktop-core, and desktop-e2e-relay
  (Linux link jobs only; not clippy/macOS/cross).
- Add concurrency group to ci.yml so superseded PR pushes cancel in-flight runs.
- Switch server-cross-compile to `cross check` on PRs, `cross build` on main.
  Catches compile/build-script errors on PRs; link-only errors surface on the
  main push which keeps full builds.
- Pin mobile job to flutter-version 3.41.7 (matches hermit) and enable caching.
- Add .cargo/config.toml with debug="line-tables-only" for local dev; applies
  to both the root and desktop/src-tauri workspaces via cargo config discovery.
- Add .vscode/settings.json with rust-analyzer.cargo.targetDir=true so RA
  checks land in target/rust-analyzer/ and stop invalidating cargo build cache.
- Remove rust-clippy and desktop-tauri-clippy from lefthook pre-push; CI
  rust-lint still gates merges. Saves 2-4m per push locally.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant