Repository navigation
feat(event-script): quoted text bounds in the range notation, exact decimal bounds from minRange and maxRange, and the lookup's list and separator checks - #555
Merged
Conversation
…ecimal bounds from minRange and maxRange, and the lookup's list and separator checks Eric's rulings on an independent review of f:rangeLookup, f:minRange and f:maxRange. A bound is one of three kinds: a canonical number (compared exactly as a decimal), text in single or double quotes (compared as written, case-sensitively - the quotes keep a zero-padded code or a case-sensitive band as text, and a quoted bound may contain the separator) or unquoted text (compared without case, as before). RangeNotation reads the lower bound up to its closing quote or the first separator and the upper bound to the end, refuses a band given as a list or a map, a second separator outside quotes, an unmatched quote, an empty quoted bound and a mix of kinds (the numeric-and-text message says a leading zero makes text and that quoting both bounds compares them as text), and caches a numeric bound as a BigDecimal. minRange and maxRange answer a whole number as a long and any other number as its exact decimal text - the DECIMAL convention; f:double converts it when a floating-point output value is wanted, as the guides now say, which also state that a value must be shaped like the bounds (dates and times in ISO-8601 order, zero-padded). Pinned by the shared range-bounds-vectors.json (52) and range-lookup-vectors.json (48), the extended fixture unit-test-range-bounds-1 (a fee band table with decimal bounds converted by f:double; a quoted zero-padded product-code table), the plugin tests and the gate test; docs, the help page and the rebuilt bundle; CHANGELOG Unreleased item 1 rewritten to the final semantics.
acn-ericlaw
added a commit
that referenced
this pull request
Oct 11, 2026
acn-ericlaw
added a commit
that referenced
this pull request
Oct 11, 2026
…- the refusal test split, the nested ternary unfolded, the folded value never nullable; javadoc wording (#556) Sonar on main after #555: RangeBoundsPluginTest.shouldRefuseWhatRangeLookupRefuses counted 44 assertions (limit 25) - now four methods by refusal family; Bound.unquoted nested two ternaries - the kind is its own statement; resolveText folded the value through the nullable bound helper - the value is folded on its own, the helper documented as the bounds' (an open end is null). No behaviour change: the plugin, gate, vector and graph tests are green. The javadoc wording of the two bound plugins, the lookup and the vector test is Eric's touch-up, smoothed.
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
Eric's rulings on an independent review of
f:rangeLookup,f:minRangeandf:maxRange(#552, #554), on both engines (the Rust twin is Accenture/mercury#381, Increment 178).'0020',"2026-11-15") compares as written and case-sensitively, and the quotes keep a zero-padded code or a case-sensitive band as text; a quoted bound may contain the separator. Unquoted text compares without case, as before, so every table of v4.12.23 behaves the same. A range, and every band of a table, is one kind; a mix is refused by name, with the hint that a leading zero makes text and that quoting both bounds compares them as text.f:minRangeandf:maxRangeanswer a whole number as a long and any other number as its exact decimal text, theDECIMALconvention where a double would round it;f:doubleconverts it when a floating-point output value is wanted, and the guides say so...outside quotes (a..b..c,1...2), an unmatched quote and an empty quoted bound; a numeric bound is parsed once when the table is read.RangeNotationreads the notation for the three plugins (the lower bound up to its closing quote or the first separator, the upper bound to the end). Pinned by the sharedrange-bounds-vectors.json(52 vectors) andrange-lookup-vectors.json(48), both byte-identical with the Rust repository, the extended fixtureunit-test-range-bounds-1(a fee band table with decimal bounds read back as text and converted withf:double; a quoted zero-padded product-code table), the plugin tests and the gate test. Docs: the syntax guide, the flow schema reference, the skills reference, the AI agent guide andhelp graph-data-mapperwith the rebuilt bundle (index-DPKAiH17.js); CHANGELOG Unreleased item 1 rewritten to the final semantics.Why
The review found that a band written as a list was read as text, that zero-padded codes made a table mixed with no way to say "text", and that a decimal bound lost precision as a double. Quoting makes the author's intent explicit, exact text keeps the engine's high-precision rule, and the new refusals turn two silent wrong answers into messages.
Verification
mvn -o -q -pl system/event-script-engine teston the plugin, lookup and gate tests;mvn -o -pl system/minigraph-playground-engine teston the two vector tests andGraphTaskTest(23 tests, 0 failures);SkillSnapshotTestgreen.scripts/check-doc-canon.py,check-minigraph-grammar.pyandcheck-rest-automation-grammar.pyOK.Co-Authored-By: Claude Fable 5.1 noreply@anthropic.com
🤖 Generated with Claude Code