Repository navigation
docs: document repeated-metadata strictness as deliberate difference P12 - #3091
Merged
Merged
Conversation
Contributor
📊 Benchmark Results
vs base, measured in this run
A difference counts only when it clears the combined spread of the two measurements, per shape (2σ: What do these numbers mean?
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Contributor
✅ Compatibility Test Results
What's tested
Full results available in workflow artifacts |
robcohen
force-pushed
the
docs/duplicate-meta-stricter
branch
from
November 29, 2026 00:40
296cf28 to
35f0e16
Compare
…rror difference P12 beancount 3.2.3 stays silent on a transaction or posting metadata key repeated with the same value as its first one when that value is TRUE / FALSE, an empty or one-character string, an account, a tag or empty, and compares each repeat with the first value. rledger reports every repeat (#2897), on purpose. Document it as P12 in compatibility.md, restate the inline comment at report_duplicate_metadata from black-box observation, and extend the pinning test to postings, empty values and a repeat back to the first value. No behavior change. Co-Authored-By: Claude Opus 5.5 <[email protected]>
robcohen
force-pushed
the
docs/duplicate-meta-stricter
branch
from
November 29, 2026 00:45
35f0e16 to
a212f18
Compare
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
Records rledger's stricter handling of a repeated metadata key as a deliberate parse-error difference (new P12 in
docs/reference/compatibility.md). Behavior does not change.report_duplicate_metadata(cst/convert.rs): the inline "Stricter than Python" comment now describes beancount's behavior as observed from outside, and points to P12 and the pinning test.test_parse_reports_a_repeat_with_an_identical_value_unlike_python(tests/metadata_shapes.rs) now also covers postings, an empty value (kk:), and a third line that repeats the first value.How beancount behaves (checked against beancount 3.2.3 with
bean-check/parser.parse_string)TRUE/FALSE, an empty or one-character string, an account, a tag, or empty.Assets:Afollowed by the string"Assets:A"."a","b","a"gives one error in beancount and two in rledger.TRUE,FALSE,TRUEbehaves the same way.open,note,event,price,balance) report no repeat at all, in both beancount and rledger.rledger reports every repeat. This follows the Python compatibility policy: the quirk can be fixed locally, and the maintainer decided not to copy it in #2897.
Harness
compat-parse-error-parity.py --checkandcompat-semantic-parity.py --checkboth pass on the unchanged manifests (semantic match rate 99.93%).Testing
cargo test -p rustledger-parsercargo test -p rustledger --test upstream_checks_testcargo clippy -p rustledger-parser --all-features --all-targets -- -D warnings--checkruns🤖 Generated with Claude Code