You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
platform-wallet: name the resumable lock for every local failure before a funded flow's first dispatch #6286
In every asset-lock-funded flow, a local failure that happens after the Core lock exists but before the first Platform transition is signed or sent, and that a resume of the same lock could get past, should be classed as refused before dispatch. Then AssetLockManager::with_funded_lock / hold_resumable_lock names the still-resumable lock as held (PaymentDelivery::LockHeld) instead of answering MaybeSent with no lock. Failures after a possible dispatch stay MaybeSent.
#5928 (e08ff1d) applies this to the first Orchard proof of shield funding (join_initial_proof). The sites below still answer MaybeSent with no lock (paths under packages/rs-platform-wallet/src/, at that commit).
Sites
Shield funding, first attempt inside the submit closure (wallet/shielded/fund_from_asset_lock.rs, the submit_with_chain_lock_fallback closure): the fee recompute, is_bound_to, the re-proof after a protocol-version change, and a second VersionMoved all map to dash_sdk::Error::Generic. A blanket before_dispatch there would be wrong, because the closure also runs after attempts that may have been dispatched. It needs an SDK error the wallet classes NotSent. maybe_dispatched already turns that into StateTransitionResultUnconfirmed after a possible dispatch.
Proof wait after a fresh build: a persister lookup failure becomes AssetLockProofWait (wallet/asset_lock/build.rs, wait_for_funded_asset_lock_proof; sync/proof.rs, wait_for_proof / validate_or_upgrade_proof). It affects every fresh funded flow.
IS→CL fallback after an InstantSend timeout: the same lookup failure in upgrade_to_chain_lock_proof, reached from resolve_chain_proof_after_is_timeout (wallet/asset_lock/orchestration.rs). No transition exists yet at this point.
Invitation after its row is saved (wallet/identity/network/invitation.rs): proof-wait errors, export_invitation_private_key, encode_invitation_uri. This flow never submits a transition, and the way on is the reclaim of the lock.
Out of scope here
An unknown Core broadcast outcome, and a resume whose proof wait expires: hold_resumable_lock names these MaybeSent on purpose. Changing that is a policy change.
Activity