Repository navigation
Conversation
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1cca8cd82b
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| } | ||
|
|
||
| errs = append(errs, validateCollectArtifacts("cases.defaults.collect_artifacts", cfg.Cases.Defaults.CollectArtifacts)...) | ||
| errs = append(errs, validateCaseLimits("cases.defaults", cfg.Cases.Defaults.MaxTurns, cfg.Cases.Defaults.TimeoutSeconds)...) |
There was a problem hiding this comment.
Preserve the default-timeout opt-out
For suites that set cases.defaults.timeout_seconds: -1 to disable the case deadline, this new default-scope validation breaks both run and validate. applyDocumentedDefaults explicitly preserves that sentinel (internal/config/loader.go:86-96), an existing loader test covers it (internal/config/loader_test.go:486-499), and withCaseTimeout honors negative defaults as no deadline rather than falling back. Zero cannot replace it because the loader rewrites zero to 300 seconds. Preserve this opt-out at the defaults scope, or provide a replacement before rejecting it.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Fixed in 3014577. Validation now covers only per-case constraints, so cases.defaults.timeout_seconds: -1 still disables the deadline. The case-level error explains how to opt out.
cases.defaults.timeout_seconds: -1 disables the case deadline, and the loader keeps it on purpose. A negative default max_turns likewise skips the turn-count check for scripted turns. Validate only the per-case constraints, where a negative value silently fell back to the defaults, and say in the error how to opt out.
Summary
A case could set
constraints.timeout_secondsorconstraints.max_turnsto-1. The evaluator only uses positive case values, so a negative one silently fell back to the eval default.validateandrunnow reject a negative per-case value and name the field. The error also says how to get the intended behaviour:0inherits the default, andcases.defaults.timeout_seconds: -1disables the deadline.cases.defaultsis not checked. A negative default timeout is the documented opt-out from the case deadline: the loader preserves it, andwithCaseTimeouttreats it as no deadline. A negative defaultmax_turnslikewise skips the turn-count check for scripted turns.Test plan
A validator test runs
-1,0and1at both scopes. Defaults accept all three, and constraints reject-1with both field names in the error. The existing loader test for the-1default opt-out still passes.Local checks:
go test -race ./...andmake verify.