Repository navigation
One text and one fingerprint for a value, written down for every port - #29
Merged
Merged
Conversation
spec/fingerprints.yaml states what a condition reads out of a value, the in-share fingerprint, the request digest a person's yes is bound to and the snapshot digest tool-snapshot-digest: pins, with 61 rows as JSON text, and marks the six rows whose answer turns on how a number was written. test_one_fingerprint_in_every_port.py holds the reference to every row.
…gerprint-in-every-port # Conflicts: # CHANGELOG.md # README.md # docs/90-REVIEW.md # site-docs/index.md # site-docs/status/verified.md
Contributor
Author
|
Merged master (2234608) into this branch. CI on the merged head: |
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 a condition reads out of a value, the share
in-share:puts it in, the digest a person's yes is bound to and the digesttool-snapshot-digest:pins have to come out the same in every runtime, or two runtimes disagree about the same run: a canary sends different customers down the new path, an approval answered in one runtime does not apply in another, a pinned server reads as changed. All four were defined only by what the reference adapter does, in three JSON spellings across three files (conditions._text,suspension.request_digest,mcp_bridge.digest_of). This writes them down as a table both ports are held to, the wayspec/comparisons.yamlholds= 80.Nothing changes in what any of them computes.
What changes
spec/fingerprints.yaml: the four encodings in words, and 61 rows, each value written as JSON text so a row means the same thing in every language:İ,Σandß, records with keys out of order, nested lists);5%and as0.95, a value that differs only in case and spaces landing in the same bucket,0%and100%);looks-like:on the five built-in detectors (11 rows) and on declared patterns as the reference'srereads them (9 rows, includingend$holding on"the end\n"and\sholding on U+001F, where an ECMAScript engine answers the opposite).number-as-written: yeson the six rows whose answer turns on how a number was written:1.0against1,1e+20, an integer past 2^53. The reference keeps all three; a port whose numbers are one type cannot.adapters/python/tests/test_one_fingerprint_in_every_port.py(64 tests) holds the reference to every row throughconditions.holds,suspension.request_digestandmcp_bridge.digest_of, keeps a floor under each part, and fails if a number-turning row is unmarked or a marked row turns on no number.Evidence
sort_keys=Truefromrequest_digestfails the four request-digest rows whose argument keys are not written in sorted order, and nothing else.test_the_documentation_site_tells_the_truth.pywith it: 78 passed, 5 skipped (they need a built CLI). No source file changes, so the rest of the suite is untouched; the headline-count test needs the whole suite in one session and was not run here.@budmh/pact-schemapactCanonicalText,pactShareBucket,pactRequestDigest) agrees with 30 of the 36 rows of those three parts and differs on exactly the six marked rows.For the maintainers to decide
{"by": 1.0}as{"by": 1}before it computes anything, so the Pythonjson.dumpsform cannot be reproduced there, and a digest over such arguments differs. Proposal: keep today's form as version 1 and give digests a versioned prefix (pyjson1:for it), then add RFC 8785 (JSON Canonicalization Scheme) as version 2 for new digests, which writes numbers the ECMAScript way in every language. A runtime then compares only digests of one version. Not done here because it changes every stored digest.looks-like:patterns are read by Python'sre. ECMAScript differs on$and\s(the declared rows), and Rust'sregexrefuses look-around, which the built-incard numberpattern uses. Proposal: state the portable subset in the specification and havepact checkrefuse a declared pattern outside it (look-around, back-references,\Z, possessive quantifiers), with$defined as end of text only. Not done here because it changes whatpact checkaccepts.🤖 Generated with Claude Code