NUT-XX pubkey quote discovery: sweeper reconcile + cdk pin cba8469b #21
Loading…
Reference in a new issue
No description provided.
Delete branch "agent/nutxx-pubkey-lookup"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The translator's wallet now discovers its mint quotes by locking pubkey — a 15s reconcile loop asking the mint for all still-mintable quotes locked to its key — instead of depending on per-quote notifications that can be dropped. Re-pins cdk from
7011eebctovnprc/cdkcba8469b(same NUT-XX lineage, plus the pubkey-encoding fix and theonly_mintablelookup filter this branch uses). Nothing changes for the pool or mint protocol surface; the mint's existing lookup endpoint gains the only_mintable filter and pubkey-encoding fixes from the cdk bump, and the wallet gains the lookup API. If this is wrong, revert the merge — master stays functional on7011eebc.This branch is the base of the epoch milestone stack (#13): merging it unblocks the epoch-mechanics and multi-unit-sweeper PRs.
Refs #7.
Risk
The cdk pin moves in all three in-repo places together (
roles/Cargo.toml,protocols/Cargo.toml,devenv.nix);roles/Cargo.lockkeeps the MSRV-pinned transitive deps (time0.3.41 family) — a fresh re-resolve would break the devenv toolchain (issue #10). The old 0xC0 notification path is retained but its wallet-side fetch is disabled; discovery is sweep-only.Validation
Live-run validated on the dev stack 2026-08-10: 64 quotes / 662 ehash minted via pubkey reconcile, including 12 quotes whose notifications were deliberately dropped; wallet and mint databases reconcile exactly. Branch merged with current master (docs + 0.17 bump) with pins kept at
cba8469b; conflict resolution verified: single[patch]block, singlecdkCommit, zero stale revs, MSRV lock pins intact.The MintQuoteNotification (0xC0) handler's fetch_mint_quote(quote_id, Custom("ehash")) call is now redundant: the quote sweeper's pubkey reconcile (Wallet::mint_quotes_by_pubkey) is the discovery source of record. Comment out the fetch, leaving the payload decode, the quote_id/amount extraction, and the info! logging in place so the notification is still observed and logged, just no longer acted on. The rest of the SV2 plumbing is untouched: the pool poller, the MintQuoteNotification/MintQuoteFailure message types, and the mint-side send all remain as-is. Retained but now-unused import and struct field are marked #[allow(...)] with a note rather than removed, so re-enabling the fetch later is a one-line uncomment.Adversarial review findings.
Merge verification (all clean):
49edec22has an empty combined diff (no evil-merge content); vs the validated branch tip it adds exactly master's three docs files; vs master only branch work + the declared pin supersession, with nothing from master lost (files the 0.17 bump touched that aren't in this diff are byte-identical to master). Single[patch.crates-io]per workspace, singlecdkCommit, all 16 lock entries atcba8469b, MSRV pins intact (time0.3.41 /serde_with3.17.0 /darling0.21.3 /simple_asn10.6.3), zero stale revs from all 12 superseded hashes, zero conflict markers; the quote.rs resolution (Custom(Arc<str>)form) is the only one that compiles at the kept pin.should-fix (body text) — "the mint gains the NUT-XX lookup endpoint from the cdk bump" is false: the
/mint/quote/pubkeyroute is identical at master's pin7011eebc. What the bump actually delivers is theonly_mintablefilter + pubkey-encoding fixes mint-side and the lookup API wallet-side. Corrected in the body so a future bisect/revert doesn't misjudge master's capabilities.Verdict: textbook merge, nothing lost; body corrected.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.