Skip to content

docs: Tamga receipt-binding review case with pinned replay evidence - #209

Merged
safal207 merged 8 commits into
mainfrom
docs/tamga-binding-case-20261011
Oct 12, 2026
Merged

safal207 merged 8 commits into
mainfrom
docs/tamga-binding-case-20261011

Conversation

@safal207

@safal207 safal207 commented Oct 10, 2026 •

Copy link
Copy Markdown
Owner

This PR publishes a bounded historical Tamga receipt-binding comparison and a reproducible evidence package. The review follow-up fixes incomplete verifier-payload assertions, distinguishes the branch base from the evidence-bearing snapshot, records both fresh replay outputs separately, and rejects invalid offline source packets before fetching or executing source code.

Historical subject: goun7/tamga-protocol parent 7a4bc537cb1a974bae89bfc96f9be55bc05d0b4b → fix c62d4a822d7e3546931197905e137d0eb6fb490e.

Attribution and scope: goun7 confirmed the original case at 3a6bcd1e08cbf7c85a60e70abe8ca2392afdf3d6. Tamga verifier implementation and native AT-007g/h regressions belong to goun7. Independent review, historical reproduction, and this repository's reproducer/oracle tests belong to Alexey Safonov (safal207), with AI assistance. The author's accuracy confirmation is not a formal approval of this PR or its subsequent changes.

Review fixes at 95350a307dc4adab04fbe5bee26eccd77f163bb2:

  • Compare complete expected success/failure JSON, including hashes, ordered checks, and scenario-specific error; retain strict boolean, exit-code, and stderr checks.
  • Read offline source packets explicitly as UTF-8, including on non-UTF-8 locales. Validate the contents object and six string entries before any network fetch or verifier execution; only absence of --source-packet selects online mode.
  • Label f13e586ea9118e026c69438b8c93d0585b8e38ba as the branch base; pin the original evidence snapshot and original/revised reproducer blob IDs and SHA-256.
  • Keep original results.json unchanged and add two distinct fresh outputs plus their comparison/digests. The missing original repeat is not reconstructed.
  • Add fourteen payload-oracle regressions and eight offline-packet regressions (22 tests total), with a dedicated External validation CI job.
  • Commit the exact UTF-8 offline source packet, its digest/blob identity, upstream Apache-2.0 license, and source notices. Record the working directory. CI now also replays both historical matrices offline and compares the reports.

Executed local verification: revised reproducer matched 8/8 on each of two runs, with byte-identical reports and six verified source identities per run. Complete outcomes agree with the original historical matrix. Literal-Unicode UTF-8 packets now work under LC_ALL=C with Python UTF-8 mode disabled. All 22 tests pass, including main-boundary tests proving invalid supplied packets cause neither downloading nor execution. Restoring the old weak predicate produced fourteen failing unittest entries. A clean temporary directory using only the published inputs passed the same tests and replays. All seven replay-package artifact identities were checked.

Updated case · Evidence and capability matrix · Fresh replay record · First output · Repeat output · Original primary results

Boundary: fixture consistency and receipt binding only. A consistently rewritten fixture still passes. Receipt authentication, real operation execution, settlement finality, buyer receipt/acceptance, effect count, and exactly-once are not established. Current Tamga/x402 releases are not assessed; links to x402 issue #3379 document only this Tamga review-to-fix history. Full upstream suite and CGQA engine were NOT_RUN for the historical comparison and fresh verifier replay.

goun7 is comfortable linking the historical case from fixture documentation if the historical-commit note stays visible. No published upstream link, Tamga adoption of ContractGraph-QA, project endorsement, or current-release security guarantee is claimed.

Current-head delivery: At 95350a307dc4adab04fbe5bee26eccd77f163bb2, all eight GitHub Actions workflow runs and all fifteen check runs passed. The Tamga job executed 22 tests plus both offline historical matrices (8/8 each), and successfully compared the generated reports. All five earlier P2 threads have fix replies and are resolved. The final Qodo-style Codex review completed on this head and reported no major issues; this automated review is not formal maintainer approval. CodeRabbit automatic review was skipped and Qodo is paused after its trial ended. Independent third-party reproduction and final PR review remain separate steps. Merge requires a separate decision.

@coderabbitai

coderabbitai Bot commented Oct 10, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: acdf69f6-9313-465d-a8b4-13e083b26274

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copy link
Copy Markdown
Owner Author

@goun7 — would you check the attribution and technical scope of this historical Tamga case?

Read the case · reproducer · raw results

Implementation and native regression credit is yours; the independent review and fresh comparison are attributed to safal207. Across parent 7a4bc537 and fix c62d4a82, four scenarios matched all eight expected outcomes, with an identical repeat. Both selected stale-field mutations are accepted before and rejected afterward at the expected checks.

The consistently rewritten fixture still passes, intentionally bounding the result. The case explicitly excludes receipt authentication, execution, settlement finality, buyer receipt/acceptance, effect count, and exactly-once. It describes those historical commits, not current releases; the full upstream suite was not rerun.

Author accuracy review is marked pending. If accurate and useful, would you be comfortable linking the case from the relevant fixture documentation? Corrections are welcome here. Prepared with AI assistance.

@goun7

goun7 commented Oct 11, 2026

Copy link
Copy Markdown

Checked the attribution and the technical scope — the attribution is accurate, and the scope is stated correctly.

Implementation and native regressions are mine; the independent review and fresh reproduction are yours. That is recorded the right way in the case, and the credit split matters here because the two roles genuinely produced different things: the regressions were written against the behavior as it was being fixed, and your reproduction re-derived the same outcomes from pinned commits without that prior knowledge. The eight-for-eight match across four scenarios, with an identical repeat, is what makes the historical comparison trustworthy rather than merely self-consistent.

The scope boundary is where I would want it: fixture consistency and receipt binding, with receipt authentication, execution, settlement finality, buyer acceptance, effect count, and exactly-once explicitly excluded. The mutated-fixture control that still passes is the detail that bounds the result — it proves the verifier is checking the stale fields rather than rejecting anything that differs from a memorized fixture. And scoping it to those two historical commits, rather than to current releases, is the honest framing.

I am comfortable linking it from the fixture documentation, with the historical-commit note kept visible so nobody reads a bounded reproduction as a standing guarantee. A case study that states its own boundary this clearly is more useful than a stronger claim that would be wrong.

@safal207
safal207 marked this pull request as ready for review October 11, 2026 20:37
@qodo-code-review

Copy link
Copy Markdown

ⓘ Qodo reviews are paused because your trial has ended. Ask your workspace admin to add credits to resume reviews. Manage billing

Copy link
Copy Markdown
Owner Author

@codex review

Please perform a Qodo-style, bug-focused review of this PR at head dcceead958e1ade2011590f4a7b3aa0372165f91 against base f13e586ea9118e026c69438b8c93d0585b8e38ba. Use the current repository instructions and review all four added files, including the reproducer and recorded results.

Prioritize:

  • Correctness and failure handling in external-validation/tamga-binding/reproduce.py: source identity verification, fixture mutations, expected JSON/exit-code/stderr checks, and false-positive paths.
  • Whether the four-scenario/eight-invocation matrix and recorded results actually support the case's bounded claims; test adequacy, determinism, and reproducibility.
  • Attribution and scope consistency across the case, EVIDENCE.md, and PR description. goun7's confirmation confirms attribution and technical scope, not formal PR approval.
  • Preservation of immutable historical Tamga revisions and primary evidence, with no conflation with other x402 studies and no unsupported authenticity, execution, settlement-finality, exactly-once, adoption, or endorsement claims.

For each actionable finding, provide severity (P0–P3), exact file/line, concrete triggering scenario, expected versus actual behavior, impact, and the smallest justified fix. Separate confirmed bugs, unresolved questions, and optional improvements; avoid speculative findings and cosmetic churn.

Report tests actually executed, skipped checks, and remaining coverage gaps. Repository CI success must remain distinct from the recorded historical Tamga reproduction. If no actionable bugs are found, say so explicitly with the review boundary.

Review only; do not change files, commit, merge, deploy, or perform real provider/payment actions.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 11, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-11T21:04:27.504757Z 95350a3 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: dcceead958

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link
Copy Markdown
Owner Author

@codex review

Please re-review PR #209 at current head 8b96f1cd2c5b4bf2d754294536ed857f071c487e against base f13e586ea9118e026c69438b8c93d0585b8e38ba, using the Qodo-style, bug-focused scope of the prior request.

All three prior P2 findings are addressed: complete expected-payload comparison with fourteen negative-path oracle tests; explicit base versus evidence snapshot and original/revised harness hashes; separately committed fresh first/repeat reports with a digest/comparison manifest. The original recorded results remain unchanged. A confirmed locale bug is also fixed by reading offline packets as UTF-8.

Local validation: 8/8 outcomes on each of two byte-identical fresh runs; fourteen oracle tests pass; the prior weak predicate produces fourteen failing unittest entries. Please verify the fixes and report any remaining concrete bugs, false-positive paths, evidence inconsistencies, or test gaps with severity/file/line and a minimal fix. Distinguish fresh replay from the unrecorded original repeat and repository CI from Tamga reproduction.

Review only; do not edit, commit, merge, deploy, or perform real provider/payment actions.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 8b96f1cd2c

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link
Copy Markdown
Owner Author

@codex review

Please perform another Qodo-style review of current head 5abd2d4f4617e205062984349b7e4d7301bf1ef0 (review only; do not edit or merge). Focus on actionable correctness/evidence bugs with priority, concrete failure case, and minimal fix. Prioritize the offline-source boundary, complete JSON outcome assertions, immutable historical attribution/source pins, and replay provenance.

This head addresses the second review's falsy offline-packet finding: --source-packet is validated as a contents object with six required strings before the source loop, and main selects offline mode by explicit None comparison. Invalid supplied packets fail before any download or verifier execution. Fourteen payload-oracle tests plus eight packet tests pass locally (22 total); main-boundary mocks assert that both urlopen and subprocess.run remain unused for invalid packets.

Both fresh executions still match 8/8; separately committed outputs are byte-identical and their updated manifest binds the new harness blob/digests. Original results.json remains unchanged. Historical Tamga source pins and claim boundaries are unchanged; goun7's confirmation applies to the original historical case, not these follow-up changes. CI for this new head is being checked separately.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5abd2d4f46

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link
Copy Markdown
Owner Author

@codex review

Please repeat the Qodo-style, bug-focused review on current head 95350a307dc4adab04fbe5bee26eccd77f163bb2 (review only; do not edit or merge). Verify the prior five P2 fixes and any remaining concrete correctness, evidence-provenance or test gaps.

The latest missing-offline-input finding is fixed: utf8-source-packet.json is now committed byte-for-byte as used by the local review replay; the manifest records its 16070 bytes, SHA-256, Git blob, and command working directory. All six decoded source strings retain their upstream blob identities. Both historical Tamga commits license those files under Apache-2.0; the exact upstream license and source/package notices are included without treating goun7's accuracy confirmation as license permission.

A clean temporary directory containing only the committed script, tests, packet and notices passed 22 tests and two offline eight-invocation matrices. Both reports match the committed fresh outputs byte-for-byte. CI now runs the 22 oracle/packet regressions and replays the historical matrix twice with the committed offline packet, comparing the reports. CI for this new head is being checked separately.

Original results.json remains unchanged; historical source pins, engineering attribution and scope boundaries are unchanged. A consistently rewritten fixture still passes. No receipt-authenticity, real-operation/payment, exactly-once, current-release security, project-adoption or endorsement claim is made.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. More of your lovely PRs please.

Reviewed commit: 95350a307d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@safal207
safal207 merged commit 38755bb into main Oct 12, 2026
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants