Skip to content

Re-pin two_party_escrow (mainnet and preview) to the latest accept-path optimization#237

Merged
Unisay merged 1 commit into
mainfrom
yura/tpe-vs-scalus
Jul 8, 2026
Merged

Re-pin two_party_escrow (mainnet and preview) to the latest accept-path optimization#237
Unisay merged 1 commit into
mainfrom
yura/tpe-vs-scalus

Conversation

@Unisay

@Unisay Unisay commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

Updates the two_party_escrow Plinth_1.65.0.0_Unisay default and its Plinth_1.65.0.0_Unisay_preview counterpart to plinth-cape-submissions d078652 (current main HEAD). The change is an accept-path optimization pass: it compares the compile-time script credential instead of locating the own input by out-ref, fuses the withdrawal scan into the seller-payment fold, shares one TxInfo spine walk across inputs/outputs/signatories, reads lovelace positionally with adaOf instead of an assetAmount key lookup, and locates the single deposit output with findUniqueE in one pass.

Result

Happy-path total_fee_lovelace, measured against scenarios/two_party_escrow/cape-tests.json:

Submission old fee new fee delta
Plinth_1.65.0.0_Unisay (mainnet, changPV) 101588 73594 -27.6%
Plinth_1.65.0.0_Unisay_preview (van Rossem) 83342 62722 -24.7%

On the mainnet changPV evaluator the escrow now costs 73594 lovelace, a 27.6% reduction from the current committed default (101588).

What changed

Both submissions are updated in place: the .uplc, metrics.json, metadata.json, and source/README.md. The source pin moves to d078652; the compiler (Plinth 1.65.0.0, commit b2db5126) is unchanged. The mainnet default keeps its ["Plinth"] flags, and the preview keeps ["Plinth", "BuiltinCasing"] with min_plutus_version = 1.65.0.0 (its preview-only dropList decoder step is retained on top of the accept-path work). The retained Plinth_1.65.0.0_Unisay_asdata variant is untouched.

Source and verification

The mainnet artifact is re-measured with the measure evaluator (changPV, PlutusTx.Eval 1.45.0.0); the preview with measure-preview (van Rossem / PV11), since the default verifier rejects preview submissions by design. Both keep all 47 expected evaluation outcomes (10/10 on the happy-path aggregate). Both JSON files validate against the repo schemas, and all eight changed files are treefmt clean.

@Unisay Unisay requested a review from Copilot July 8, 2026 14:27
@Unisay Unisay self-assigned this Jul 8, 2026

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 wasn't able to review this pull request because it exceeds the maximum diff size. Try reducing the number of changed files and lines, and requesting a review from Copilot again.

… accept-path optimization (d078652)

Update the Plinth_1.65.0.0_Unisay default and its _preview counterpart to
plinth-cape-submissions @d078652. The accept-path pass (compile-time credential
compare, fused withdrawal scan, shared TxInfo spine walk, positional adaOf lovelace
read, findUniqueE deposit lookup) drops happy-path total_fee 101588->73594 (mainnet
changPV, -27.6%) and 83342->62722 (preview van Rossem, -24.7%). All 47 outcomes hold.
@Unisay Unisay force-pushed the yura/tpe-vs-scalus branch from 9133e82 to 9a0f2ee Compare July 8, 2026 14:30
@Unisay Unisay changed the title Re-pin two_party_escrow (mainnet and preview) to the tpe-vs-scalus build Re-pin two_party_escrow (mainnet and preview) to the latest accept-path optimization Jul 8, 2026
@Unisay Unisay marked this pull request as ready for review July 8, 2026 14:33
@Unisay Unisay merged commit 5e5a11e into main Jul 8, 2026
6 checks passed
@Unisay Unisay deleted the yura/tpe-vs-scalus branch July 8, 2026 14:38
@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

🚀 PR Preview Deployed

Preview URL: https://intersectmbo.github.io/UPLC-CAPE/pr-237/

The preview site is automatically updated on every push to this PR and will be removed when the PR is closed.

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