Skip to content

feat: managed checkout and cross-transport revocation checks (#74–76) - #111

Merged
LIghtJUNction merged 13 commits into
mainfrom
work/issues-74-76-continuation
Sep 27, 2026
Merged

LIghtJUNction merged 13 commits into
mainfrom
work/issues-74-76-continuation

Conversation

@LIghtJUNction

@LIghtJUNction LIghtJUNction commented Sep 27, 2026 •

Copy link
Copy Markdown
Contributor

Scope

Refs #74, #75, #76. This delivers a bounded implementation; keep the umbrella issues open for remaining acceptance.

  • Preserve orders.buy@1 and the original escrow-v1 digest. Add signed orders.buy@2 with an immutable package digest and atomic in-site preparation. Optional auto_accept requires the explicit escrow-instant-v1 policy.
  • Commit funding, objective signed settlement, source proof, ledger references, delivery, replay result and mail outbox together. A later signed delivery.claim@1 acknowledges receipt without paying again and validates complete signed order/delivery snapshots after restoration.
  • Recheck DeliveryTarget across preparation, reads, settlement and mail. Bind email to the buyer's verified endpoint generation/address. Send only order number, checkout username snapshot and a reauthenticated pickup link. SMTP outcomes never roll back the trade or mark delivery claimed.
  • Add actual HTTP, GET path, GraphQL, MCP HTTP, CLI subprocess and MCP stdio sharing revocation cases: current/historical content, history, explicitly projected warm-cache reads, search, Sync and independent owner grants.
  • Classify settlement actor/recipient in exhaustive legacy identity-reference checks; verify corrupt-reference rejection and repeated startup with real signed decisions without rewriting journal/ledger bytes.
  • Document versioned contracts and authority rollout prerequisites in docs/MANAGED_CHECKOUT.md.

Final verification

Tested head: 4ef3548b933e26b32a557ced12a1a046ea698844, tree b55140fa180c3c583ea48c711c0c88e493b957e1.
Full CI run 36354944861 passed all four shards and the final contracts gate on Python 3.15/PostgreSQL/Valkey:

  • 1,171 business/security tests passed: shards 283 + 301 + 316 + 271, zero failures/errors/skips.
  • 8 transport/tokenizer conformance checks passed; wheel and sdist builds passed.
  • All four downloaded artifact SHA-256 digests matched provider values. Independently checked exact msg.nodeid identities against every shard manifest: complete collection, no duplicates, omissions or skipped cases.
  • All six real-adapter sharing cases, three signed-decision migration cases, 29 checkout/target/restored-snapshot cases and eleven latest-main completion-fence cases passed.
  • Verified the built wheel contains the exact integrated worker and shared lease-fence blobs plus all new market modules.
  • The prefunded 10 MSG signed challenge → 5 MSG text+file purchase → buyer retains 5 MSG end-to-end case passed without changing total supply or replaying rewards/payments.

Earlier runs deliberately reproduced four DeliveryTarget failures, then exposed and fixed migration classification/test cache-projection assumptions. No security assertions, unknown-table refusals or immutable-journal guards were removed to make tests pass.

Integration and review

Includes the existing PR #99 dependency at c49cf90, without modifying its branch. Main 4c466717 is integrated, preserving the exact test-identity gate and all #113 tool/Git/maintenance fences. The only worker overlap was resolved by retaining every latest-main byte outside the existing mail changes, verified by Git blob hash. Main CI is unchanged; temporary source-export workflows are absent from the final tree.

Codex reported no major issues for 8aa0e12; the initial security review covered 5f8b02b. A further review was requested for merge head 4ef3548; it is not represented as completed unless the bot records completion. Copilot could not review because the requester reached its quota.

Remaining acceptance

No production deployment, money movement or credential-policy update was performed. Existing signed authority ceilings require explicit review for new operations. Full case/evidence/panel/quorum/appeal/deadline arbitration and complete recovery/doctor/selftest remain under #75. The full organization/Topic/certificate/ShareLink/restoration/attachment matrix remains under #76; unsupported ShareGrant constraints still fail closed. General default-projection/null digest normalization is unchanged. Larger packages, secret/service goods, order-inbox reference projection and deployed official fixture initialization remain outside this #74 slice.

LIghtJUNction and others added 10 commits September 28, 2026 04:28
One-use feature-branch materializer. It only applies the reviewed patch and publishes that branch; it does not merge, deploy, close issues, or weaken existing CI. The materializer removes itself before the final PR tree.
Refs #75, #76, #77. Publish the reviewed partial implementation; remaining acceptance work stays open. Remove the one-use patch materializer from the resulting tree.
Preserve main 2dd6a0d and its newly merged read/patch/LFS and SSH fixes. Compared both changesets against common base 054c213: their paths do not overlap. Retain the exact 20 reviewed patch blobs and re-run the unchanged full CI on the combined tree. Refs #75, #76, #77; acceptance remains partial.
Full combined CI 36348523874 failed with 122 collection errors because test_service imported the directory-scoped installed fixture from the bare conftest module after tests/issue_78_80/conftest.py had been imported. Let pytest resolve installed by fixture name instead, and remove the redundant re-export import in test_transfer. No fixture, production code, assertion, or CI selection changes.

Reproduced nested-conftest shadowing locally against both real test modules: 2 import errors before, all 8 selected tests collected after. Full Python 3.15/PostgreSQL CI will rerun on this commit. Refs #75, #76, #77.
…buyer-only mail (#74)

Preserve orders.buy@1 and escrow-v1. Add explicit orders.buy@2 with optional
checkout acceptance under escrow-instant-v1, separate signed delivery ACK,
current DeliveryTarget checks, and generation-bound minimal email hints.

Keep transfer legs, delivery, signed decision, replay result and mail outbox
atomic. Extend real PostgreSQL regressions for rollback, competition,
revocation, no blind SMTP retries and the prefunded bounty-to-bundle flow.
Integrate main b1ac767, preserving its CI shards, schema hardening and live
notification lease fences. Add group-reshare revocation, historical reads,
known-digest cache, search, Sync and independent-authority checks across
HTTP, GET path, GraphQL, MCP HTTP, CLI and MCP stdio.

Document versioned checkout/ACK/mail contracts and explicit remaining
acceptance. Remove the temporary source export workflow from the final tree;
the unchanged main CI now verifies all tests, conformance and builds.

Refs #74, #75, #76. Includes the unchanged PR #99 dependency slice; no
umbrella issue closure, production authority update or deployment.
Copilot AI lite review requested due to automatic review settings September 27, 2026 21:46

Copilot AI 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.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 27, 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-09-27T22:24:43.008662Z 4ef3548 Manual request
🔒 Security Review ✅ Completed 2026-09-27T21:54:45.145842Z 5f8b02b PR opened
ℹ️ 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.

Reject mismatched restored terms, funding references, settlement timestamps,
delivery IDs and preparation timestamps without touching immutable journal
or ledger triggers. Verify the domain-separated release request and original
order/evidence digests before a claim; no additional transfer is performed.

Refs #74, #75.
…hecks

Register actor and recipient as typed identity references without weakening
unknown-table rejection or modifying historical journal/ledger bytes. Add
real PostgreSQL corruption and repeated-startup regressions.

Use an explicit non-null projection for the six-adapter warm-cache test;
compact wire output omits optional null fields from default projections.
Retain every positive cache assertion and post-revocation denial check.

Refs #74, #75, #76.

Copy link
Copy Markdown
Contributor Author

Final integration follow-up at 8aa0e12d893a51c839d023fed1f21af8cca10563:

The full four-shard run at 42295ef collected 1,152 tests: 1,131 passed, 21 failed, 0 skipped/errors. All 29 managed-checkout, delivery-target and signed-snapshot tests passed. The failures were 15 legacy migration cases caused by the newly added order_escrow_decisions.body missing from the exhaustive reference classification, plus the six new adapter cache checks (default compact output omits null values before the client hashes it).

This head registers only the decision's actual identity fields (actor, recipient), keeps the unknown-table refusal and immutable journal/ledger guards, and adds two corrupt-reference cases plus a real signed-decision repeated-startup migration case. The adapter cache scenario now requests an explicit non-null projection and retains the positive not_modified assertion and every post-revocation denial assertion. General default-projection/null digest normalization is not changed or claimed fixed by this slice.

Current complete CI: https://github.com/TokenNotIncluded/msg.lmm.best/actions/runs/36353919437 . Earlier targeted passes are not a substitute for this final-head gate. No umbrella issue is closed and no production configuration is changed.

@codex security review
Please review the current head, particularly the signed settlement reconstruction and migration reference boundary added after the initial 5f8b02b review.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Keep them coming!

Reviewed commit: 8aa0e12d89

ℹ️ 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".

Integrate main 4c46671 and its exact test-identity CI gate, shared current_attempt
fence, tool/Git/maintenance completion checks and all eleven regressions.
Resolve the sole worker overlap by retaining the complete latest-main worker
outside the existing buyer-bound mail projection/configuration checks.

Before integration, head 8aa0e12 passed run 36353919437: 1160 business/security
tests plus 8 conformance checks, zero failures/errors/skips, wheel/sdist and
contracts gate. All four downloaded artifact SHA-256 digests were verified.
The integrated head is subject to a fresh full CI run; no issue closure or
deployment is implied.

Copy link
Copy Markdown
Contributor Author

Resolved the latest main conflict in 4ef3548b933e26b32a557ced12a1a046ea698844, merging 4c466717 as a real second parent. All main #113 completion fences, all eleven regression cases and the exact test-identity CI gate are preserved. The final worker blob is 69b5f68ceb6674e1ab5a6d5cad3e0e28ebf272f0; removing only this PR's existing 13-line mail projection/config/owner checks reconstructs main's exact 09bdbad480d9e0f75495cd31a8189d1bae223d06 blob. No unrelated worker changes were dropped.

The preceding 8aa0e12 run 36353919437 is fully green: shard counts 281 + 298 + 311 + 270 = 1,160 tests, plus 8 conformance checks, zero test failures/errors/skips, wheel/sdist and aggregate contracts gate success. All four downloaded artifact SHA-256 values match their provider digests. All six real-adapter share-revocation and all three legacy signed-decision migration tests passed.

Current integrated-head CI is https://github.com/TokenNotIncluded/msg.lmm.best/actions/runs/36354944861 ; it must pass separately before merge. The previous no-major-findings review at 8aa0e12 is not represented as review of this new merge head.

@codex review
Please review the current merge head, focusing on the mail branch's use of the shared completion fence. This is a main integration only; there is no new market or authorization policy change.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🚀

Reviewed commit: 4ef3548b93

ℹ️ 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".

@LIghtJUNction
LIghtJUNction merged commit 4eabfda into main Sep 27, 2026
10 checks passed
@github-actions
github-actions Bot deleted the work/issues-74-76-continuation branch September 28, 2026 10:15
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