Skip to content

feat(agents): cap CARGO_BUILD_JOBS in agent launch env#601

Merged
NagyVikt merged 1 commit into
mainfrom
agent/claude/cap-cargo-jobs-in-agent-launch-env-2026-05-17-21-02
May 17, 2026
Merged

feat(agents): cap CARGO_BUILD_JOBS in agent launch env#601
NagyVikt merged 1 commit into
mainfrom
agent/claude/cap-cargo-jobs-in-agent-launch-env-2026-05-17-21-02

Conversation

@NagyVikt
Copy link
Copy Markdown
Collaborator

Automated by gx branch finish (PR flow).

Prepend CARGO_BUILD_JOBS=max(2, floor(cpus/4)) to every agent launch
command so concurrent fleet runs don't oversubscribe the host when
child cargo builds fan out. Harmless on non-Rust agents — cargo is
the only consumer of the env var.

Tests previously hardcoded CARGO_BUILD_JOBS=8 (passed only on
32-CPU hosts); they now compute the expected value from os.cpus()
so CI on any CPU count stays green.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@NagyVikt NagyVikt merged commit b8ec4ff into main May 17, 2026
@NagyVikt NagyVikt deleted the agent/claude/cap-cargo-jobs-in-agent-launch-env-2026-05-17-21-02 branch May 17, 2026 19:15
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