Repository navigation
fix(ci): bring agent-session-failure-words.ts back under the line limit - #28086
Closed
brennanb2025 wants to merge 1 commit into
Closed
brennanb2025 wants to merge 1 commit into
brennanb2025 wants to merge 1 commit into
Conversation
Two PRs that were each under the limit together took agent-session-failure-words.ts past the 300-line max-lines rule on main. The table classifies wire refusal codes, so it belongs beside them.
Contributor
Author
|
Main fixed this in #28085 first, so this one is a duplicate. |
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.
Problem
Main's static-analysis check fails on every PR right now.
src/shared/agent-session-failure-words.tsis over the 300-linemax-lineslimit (304 counted lines):Two PRs each touched the file while it was under the limit, and each was green on its own: #27946 (name the agent when it refuses a message) and #26684 (require Codex 0.136.0 for chats). Merged one after the other, they took it over.
What changes for users
Nothing. This only moves code.
Mechanism
START_REFUSAL_RESUMABLEmoves fromagent-session-failure-words.tstoagent-session-wire-refusals.ts, unchanged. It's the table that says whether a refused agent start can be retried, or only a new chat can continue. It is keyed by the wire refusal codes, which that file defines, so a new code fails to compile right beside its definition. The failure-words file now imports the table instead of the code type.Why this approach
The table classifies refusal codes rather than wording any sentence, so the refusal-code file is its natural home. Moving it brings the failure-words file back under the limit without squeezing lines or raising the limit.
Testing
oxlintpasses on both files.tc:node,tc:webandtc:clipass.agent-session-failure-wordstests pass (84).orca-ci-checks --no-typecheck: everything passes except the local-only buntypecheck:cirunner ("Script not found check"), which fails the same way on main on this machine.