feat(codex): add per-account auto-switch thresholds - #4020
Conversation
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: trueThanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
⏳ DRAFT
What to do
Review readiness checklist
0/4 boxes ticked. This pull request was already a draft. Its draft status will be preserved after every issue above is resolved. |
e7923da to
c9bdeb4
Compare
c9bdeb4 to
fece6dd
Compare
리뷰 · 우선순위 56 / 80이 PR은 Codex 계정마다 사용량 기반 auto-switch 임계값을 따로 두는 기능이다. 전역 구조는 비교적 깔끔하다. 새 막히는 지점도 분명하다. draft=true, 라인 src/codex/routing.ts 메인테이너의 판단이 필요한 지점
너의 추천 이 댓글은 grok-bot이 작성했습니다 |
|
@lidge-jun @Ingwannu — follow-up on
Could one of you review |
|
Followed up on fece6dd and the two requested source files. The account API distinguishes a missing id (existing global update) from a supplied account id, validates null/integer 0-100, rejects unknown stored accounts, and uses the current runtime config. The main-pin path uses the effective main-account threshold. I also confirmed the shared resolver is used at the current routing and subagent threshold-read sites; the global value exposed in management state is not itself a missed routing decision. This is not a full approval of the larger account/UI change. Full-root validation is still explicitly incomplete in the description, and dev now includes the #4085 startup-policy change touching the same auth-context area. Please bring this head forward without dropping that fence, finish exact-head full validation, and retain tests proving that threshold 0 disables only proactive switching, not hard-lock/cooldown/entitlement enforcement. @lidge-jun The per-account UI/product decision and sponsorship remain yours; I have not applied a sponsorship label or waived readiness based only on these two files. |
|
Follow-up to the September 9 review in #4020 (comment), now on
The description now records the exact head and both full-run outcomes separately. Stale readiness attestations have been cleared, and the PR stays draft. This is a response to the requested implementation/validation follow-up, not full approval of the account/UI change or a substitute for maintainer security review and sponsorship. |
|
Thanks for keeping the two full-run outcomes separate. A complete single-worker inventory is useful evidence, and it should not be described as “only focused tests”; the default four-worker SIGSEGV is still a separate unresolved execution result. I am not granting a CI exception or approval from that summary. The current 42d8b74 head also contains the newly reported cooldown and save/deletion rollback fixes, which need their own source-bound review in addition to the earlier threshold-zero controls. Keep the Draft state and attach exact-head hosted CI when available; there is no need to rerun the already-passing unchanged single-worker suite merely to repeat the count. Final account/UI acceptance remains separate. |
|
Follow-up to #4020 (comment): Draft remains in place; no CI exception, maintainer approval, sponsorship, or account/UI acceptance is inferred. The complete local single-worker inventory and the unresolved default four-worker crash remain separate results. I have not rerun the unchanged passing suite or added another code commit. For the separate source-bound review of the new fixes, these links are pinned to
These are source/regression anchors for maintainer review, not a claim that the earlier two-file review approved these additions. Exact-head hosted CI status checked on September 10:
Both test workflows point to the exact head above, but neither provides a passing hosted test result yet. Could a maintainer review the three changes and take the required action on the fork workflow runs? No workflow permissions or sponsorship labels have been changed, and required hosted CI and final account/UI acceptance remain outstanding. |
Summary
0disables proactive usage switching only for that account.Custom account thresholdaccount-card control. Inherited accounts show only the disabled toggle; the percentage appears after enablement, and native duplicate number-input arrows are hidden.devthroughf94dd88f12a1a9aeb355aa9b2d7166ef5b002ac9, retaining the fix(codex): restore main policy binding after owned startup #4085 startup-policy binding fence. Add threshold-zero safety regressions and fix caller-owned main cooldown and failed-save/deletion rollback gaps found during follow-up review.Screenshot
Verification
Validated head:
42d8b74601fde4c8fba1c7c8c43a534d6e0f30e9, September 10, 2026. Runtime: repository-local Bun 1.4.2 (744846f84), macOS arm64. The tracked working tree was clean and this exact commit was pushed without rebasing or amending the reviewed history.bun run typecheckbun run test --parallel=1bun run test(four workers)SIGSEGVintests/routing/routing-policy-surface-parity.test.ts. The affected file passes alone and in the completed single-worker full run. This is not a claim that the default parallel crash is fixed or that remote CI is green.bun run privacy:scanbun run skill:surface:checkThe supported
--parallel=1option retains the full wrapper inventory, all six serial lanes,--isolate, preload, isolated homes, user lock, and full-suite timing mode. No test exclusions, relaxed assertions, disabled safety checks, or dependency-policy changes were introduced to obtain this result. The default-worker crash has not been bisected againstdev; its root cause remains unproven.Threshold-zero regressions retain these separate boundaries:
These safety regressions were also driven red with isolated mutations that bypassed hard-lock, startup binding, cooldown, entitlement, or the explicit zero override, then passed after restoration. All changes are retained in the pushed tests.
This PR remains draft. Local validation and follow-up code review do not replace maintainer security review, sponsorship, the broader account/UI product decision, or required remote CI. The default parallel-runtime failure remains explicitly recorded above.
Checklist
Review readiness checklist
This PR stays in draft until every box below is ticked. Tick all four boxes once the requirements are met: