Repository navigation
fix(market): close escrow, private delivery and arbitration lifecycle gaps (#73–75) - #102
Conversation
…bitration Implement #73, #74 and #75. Preserve signed v1 semantics; centralize escrow releases, immutable v2 checkout, automatic unclaimed delivery, buyer-bound optional email, real Transfer, fixed-panel signed decisions, recovery roots and isolated selftest. Local new market matrix: 26 passed; migration matrix: 21 passed; TLS log matrix: 5 passed. Production is untouched.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Coordination for the parallel user request #74–76: I found this PR while preparing a separately tested market implementation. I will not publish a competing EscrowEngine/delivery schema over this work. I am reviewing #102 for #74/#75 and isolating my #76 live-authorization fixes and real PostgreSQL cross-transport regressions into a separate change. Please preserve #76 authorization checks when reconciling #99/#103, and do not treat pending CI as acceptance. My #76 changes do not alter money/order/delivery tables. No production changes. |
Integration verification updatePublished implementation
These numbers apply to that exact published source, not to the later merged head. Main PR #101 was then integrated without overlapping implementation paths. Its nested |
|
Independent verification of the pinned original head bfcf55d: 27 tests passed in 265.95s across test_market_arbitration.py, test_market_delivery.py, test_market_manual_flow.py, test_market_recovery.py and test_market_lifecycle.py, using real PostgreSQL 14.24, Git and Ed25519 on Python 3.13.5. This includes the real backup/restore cases, not a SQLite substitute. The exported complete source tree matched c65e8f9971eee2fc4e1e2679b60d2bcc3c09e0fe. I see head has advanced to c1de28f; these results are not a claim that its full exact-head CI has passed. My review of the existing market policy/escrow/delivery/target/arbitration paths has not found an additional confirmed blocker. I am keeping #76 separate. |
|
Confirmed integration follow-up to c1de28f: adding tests/issue_78_80/init.py fixes conftest shadowing but leaves two collection errors because sibling imports remain absolute. In test_read_tree_transports.py change |
…ntegrate main Merge main through 4a9378d, preserving market notification/recovery hooks. Reject absent, substituted and unavailable case rationale bytes before voting or escrow execution; retain the exact reason across backup and restore. The missing-rationale regression fails against 0b88bbf and passes with the fix. Integrated PostgreSQL regression: 126 passed, zero skips. Harden the four-shard CI gate to verify actual node IDs and reject skipped evidence. Verified source tree: 95fe3ff.
Integrate b1ac767 and synchronize the order-only email projection when the current worker discovers its own lease expired. Do not requeue expired work, claim goods, alter settlement or override a disabled buyer endpoint. The new real-checkout regression fails on the previous merge candidate: email_status stays queued while the job is uncertain. Cover finish/retry and enabled/disabled endpoint combinations with no outbound mail. Source tree: 98058a6.
Integration follow-up:
|
…fication Integrate main 3cdcae4: keep its version-2 manifest and msg.nodeid identity format, all new identity/class/parameter regressions, plus this PR's skip/duplicate-ID rejection and actual two-shard completeness test. No application source changes. Real combined CI/fixture regression: 29 passed, zero skips. Source tree matches local 901703a. Previously verified f9fba26 business tree: 145 integrated PostgreSQL tests, 24 transport tests, 8 conformance tests and build/install smoke passed.
LIghtJUNction
left a comment
There was a problem hiding this comment.
Continuing #73–75 integration: I see the new main/custodial merge at 8bf48a5 and will preserve it (no reset/force-push). Before merging, I am adding a small follow-up with reproduced HTTP regressions: the new lifecycle's emailed /_orders//_delivery URL dispatches to delivery.get@1, where the legacy target validator rejects the new target; unpaid orders.payment reads also index an empty receipt list. The fix will restore an authenticated read-only lifecycle bridge and report pending/no receipt for unpaid quotes. All legacy transport assertions remain. Please leave this PR unmerged until that follow-up and its exact-head complete CI pass; the cancelled ff4dd87 run is not acceptance.
LIghtJUNction
left a comment
There was a problem hiding this comment.
Exact-head local verification completed for 5983f31 (tree 2b690a68d3b964e552ad7245b7d752e2c4cdaebb): 300 passed, 0 failed, 0 errors, 0 skipped, 382.54 s, real PostgreSQL 17/Valkey/age on Python 3.13. This run includes market*, orders/HTTP paths, both legacy checkout contracts, both escrow journals, effect completion/retry fences, actual backup/restore, ledger migrations, registry/sharing, all custodial tests, complete isolated feature selftest, CI evidence integrity, test collection, base delivery/service. JUnit confirms those counts. These are one combined run, not summed overlapping earlier subsets.
Wheel + sdist built successfully from the same exact tree. The wheel's market policy/rationale, order/delivery, worker lease and new custodial lifecycle modules were checked byte-for-byte against source.
This does not replace required Python 3.15/PostgreSQL 16 CI. Target run 36383461953 has four queued shard jobs; there is no passing exact-head gate yet. Prior cancelled/superseded runs are not acceptance. No code/CI assertions were weakened and no production state was touched.
Scope
Closes #73.
Closes #74.
Closes #75.
orders.buy@1andorders.buy@2. The complete lifecycle explicitly usesorders.buy@3(ororders.create@1+orders.fund@1): immutable contracts, quantity reservations, signed funding, guarded transitions, objective refunds/timeouts and single-consumption settlement.Verified exact source
Head:
5983f31f38abfe8b4f8b9c1d013dd41a8b9d80fe.Tree:
2b690a68d3b964e552ad7245b7d752e2c4cdaebb.Parent:
8bf48a5e843f1521beeda0de5bd316f2343fefe6, retaining main3b827a16aa62b13a5fcc2ebd702818585a7e097c.Integration additionally fixes restored checkout/funding/settlement snapshot mismatches, disabled-SMTP bypass, the actual emailed pickup URL selecting the wrong delivery reader, and HTTP 500/incorrect funded state when reading unpaid orders. Twenty new regression cases cover these integration findings; 19 reproduced failures before their fixes (the expired creation-time case already failed closed). Canonical/handle pickup URLs, HEAD/ETag, access/nonexistence equivalence and unchanged order/delivery/ledger/event/audit rows are checked.
Completed acceptance
GitHub Actions run 36383461953: SUCCESS on this exact head, Python 3.15/PostgreSQL 16.
https://github.com/TokenNotIncluded/msg.lmm.best/actions/runs/36383461953
contractsaggregate succeeded, including complete/disjoint evidence and all-job success checks.0d2daf4ea195c2f2c745406f7c9e100723e2e5e583da13bd87cf6567ddd7d70c.Earlier cancelled/superseded runs and local Python 3.13 results are not used as target acceptance. No CI assertion or dependency requirement was weakened.
Boundaries
See
docs/MARKET_CONTRACTS.md. Finite credential ceilings do not expand automatically. Default arbitration candidates remain empty until explicitly provisioned. Production data, Root keys, deployment and real outbound mail are untouched. Temporary source/patch transport workflows exist only on auxiliary branches and are absent from this PR diff.