Repository navigation
gateway tests: an escaped model is capped by its spelling, not its text - #397
Merged
Merged
Conversation
The deep run's prop_model_scanner_reads_the_model_serde_reads failed after 96,349 cases (PROPS_SEED=1792344194988825270): a `model` whose text is 200 bytes but whose escaped spelling is 520 read `unknown`. That is the scanner's documented cap (#347: an escaped capture at MAX_CAPTURE may end in a cut escape, so it reads as no name); the property's oracle measured the decoded text. The oracle now reads the spelling through serde_json's RawValue, and the counterexample is pinned as a fixed test beside a spelling under the cap. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PCAZXpS7FpjaXdEL6JLS4r
…s the rule is inclusive Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PCAZXpS7FpjaXdEL6JLS4r
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.
What
The nightly deep run (39149108709) failed
prop_model_scanner_reads_the_model_serde_readsafter 96,349 cases (PROPS_SEED=1792344194988825270).model, spelled entirely as\uescapes, with a value whose text is 200 bytes but whose escaped spelling is 520 bytes.unknown. That is its documented cap (capture_text, since gateway: fourteen defects fixed ahead of the state-as-types refactor #347): an escaped capture that reachesMAX_CAPTURE(256 bytes) may end in a cut escape, which could decode to a shorter, real name, so it reads as no name.No gateway behavior changes. Either outcome is a catalog miss and unpriced, since neither
unknownnor a 200-byte name is a catalog row.Change (tests only)
RawValue, which is independent of the scanner. An escaped spelling at or past the cap must readunknown, and that case is now asserted rather than skipped. A text under the cap whose spelling is also under it must read exactly.an_escaped_model_is_capped_by_its_spellingpins the counterexample (20 escaped units readunknown), beside a control spelled under the cap (9 units read exactly). The\uescapes are built at run time so the body carries the escapes, not the characters.Verification
cargo fmt --checkandclippy -p beyond-ai --tests -D warningspass (Linux).PROPS_SECS=500 PROPTEST_CASES=100000, passes (287 s). The default 60 s budget never reaches case 96,349.props_lexsuite passes, 8/8.🤖 Generated with Claude Code
https://claude.ai/code/session_01PCAZXpS7FpjaXdEL6JLS4r