[codex] Allow opt-in concurrent Codex runs#9
Draft
austinkennethtucker wants to merge 2 commits into
Draft
Conversation
|
|
||
| third = await request(app, "POST", "/v1/chat/completions", json=payload) | ||
| runner.release.set() | ||
| await first |
| third = await request(app, "POST", "/v1/chat/completions", json=payload) | ||
| runner.release.set() | ||
| await first | ||
| await second |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds an opt-in provider concurrency setting for local
wrapper_busy429s. The default remains one active Codex execution, but operators can setMAX_CONCURRENT_CODEX_RUNS=2when the bottleneck is the wrapper admission gate rather than upstream rate limiting.Why
The provider already had a short local queue, but bursty clients can still overlap requests and hit
code: "wrapper_busy". A second local execution slot can absorb small overlaps without changing the default conservative single-user behavior.Changes
MAX_CONCURRENT_CODEX_RUNSenv parsing, clamping, and.env.exampledocs.Validation
python3 scripts/check_repo_hygiene.pypython3 scripts/check_compose_security.pyCOMPOSE_FILE=docker-compose.image.yml CODEX_CLI_PROVIDER_IMAGE=registry.example.com/your-org/codex-cli-provider:codex-cli-provider-0.1.2 python3 scripts/check_compose_security.pyPYTHONPATH=. .venv/bin/pytest -q