Skip to content

fix: build integration client image once per run - #578

Merged
cursor[bot] merged 1 commit into
stagingfrom
cursor/integration-skip-rebuild-43d2
Jul 4, 2026
Merged

fix: build integration client image once per run#578
cursor[bot] merged 1 commit into
stagingfrom
cursor/integration-skip-rebuild-43d2

Conversation

@biodrone

@biodrone biodrone commented Jul 4, 2026

Copy link
Copy Markdown
Collaborator

Fixes #576

Summary

Integration tests were rebuilding the Go client Docker image on every start_client() call (live → VOD → notice 6b → notice 6a). That added minutes per run and contributed to disk exhaustion during local validation.

Changes

  • start_client() passes --build only on the first call per run
  • Subsequent phase transitions use --force-recreate --no-deps only (config/volume changes still apply)
  • INTEGRATION_FORCE_BUILD=1 restores rebuild-on-every-call behaviour when needed
  • Documented env var in run.sh header

Testing

  • bash -n tests/integration/run.sh (syntax)
  • Full ./tests/integration/run.sh — please run locally before merge (requires Docker + live Twitch)

Notes

Server build is unchanged (single build at startup). Only client rebuild redundancy is addressed.

Open in Web Open in Cursor 

Summary by CodeRabbit

  • Chores
    • Improved integration test startup behavior by reusing a previously built client image during repeated launches, reducing unnecessary rebuilds.
    • Added support for forcing a fresh client image build on every start when needed.
    • Clarified the script’s behavior so it’s easier to understand when builds are reused versus rebuilt.

start_client() now passes --build only on the first call (or when
INTEGRATION_FORCE_BUILD=1). Later phase transitions recreate the
container without rebuilding, cutting run time and Docker disk use.

Fixes #576

Co-authored-by: Josh J <josh@joshjacobs.net>
@coderabbitai

coderabbitai Bot commented Jul 4, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 471cb013-b351-40dc-b008-1d97bd326b26

📥 Commits

Reviewing files that changed from the base of the PR and between da96854 and cdbaadf.

📒 Files selected for processing (1)
  • tests/integration/run.sh

📝 Walkthrough

Walkthrough

The integration test script tests/integration/run.sh is modified so the client Docker image is built once per script run instead of on every start_client call. A new CLIENT_BUILT flag and the INTEGRATION_FORCE_BUILD environment variable control build behavior, while the client container is still always recreated.

Changes

Client Build Caching

Layer / File(s) Summary
Conditional build logic
tests/integration/run.sh
Adds header documentation for INTEGRATION_FORCE_BUILD, introduces a CLIENT_BUILT flag, and updates start_client to build only on first call or when forced, while always force-recreating the client container.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Poem

A rabbit once rebuilt with glee,
Four times over, needlessly!
Now one build, then flags held tight,
The client hops back into the night—
Recreated fresh, but built just once, just right. 🐇

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely summarizes the main change: building the integration client image once per run.
Description check ✅ Passed The description includes the fix reference, summary, changes, testing notes, and override behavior, which covers the template intent.
Linked Issues check ✅ Passed The changes match #576 by building the client once, preserving --no-deps, and adding an INTEGRATION_FORCE_BUILD override.
Out of Scope Changes check ✅ Passed The PR stays focused on tests/integration/run.sh and does not introduce unrelated code changes.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch cursor/integration-skip-rebuild-43d2

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@cursor
cursor Bot merged commit 2e3da1c into staging Jul 4, 2026
8 checks passed
@cursor
cursor Bot deleted the cursor/integration-skip-rebuild-43d2 branch July 4, 2026 05:56
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.

2 participants