Skip to content

SDK: retry an instant asset lock proof refused for too many inputs (10534) with a chain proof (PV15) #5826

Closed

Description

@shumkov

Expected Behavior

From protocol 15 (#5825), a chain asset lock proof is no longer held to the 100-input cap (max_asset_lock_transaction_inputs). When Platform refuses an instant proof with IdentityAssetLockTransactionTooManyInputsError (10534), the SDK should retry the same transition with the chain proof for that outpoint, the same way it already does when an instant proof makes the transition too large.

Current Behavior

needs_chain_lock_proof (packages/rs-sdk/src/platform/transition/asset_lock_submission.rs) retries with a chain proof only for an invalid InstantSend signature or a StateTransitionMaxSizeExceeded error that a chain proof would fit. An asset lock with roughly 101–108 inputs fits the 20 KiB transition limit, so Platform answers 10534 and no chain-proof retry happens. Above about 108 inputs the size fallback already applies. Both the wallet's submit_with_chain_lock_fallback and the invitation claim fallback use this classifier.

Possible Solution

In the shared SDK retry policy, treat 10534 on an instant proof as retryable with a chain proof. Guard it with the proof's own transaction having more inputs than the error's max_inputs, as the size path measures the proof itself, so the retry does not depend on the SDK's protocol version. Update the invitation flow's message, which currently says only "too large". Callers keep reusing this policy. Add a case to chain_lock_fallback_tests.

On a protocol 14 network the retry waits for a chain lock and gets 10534 again, the same cost the size fallback already has there.

Context

Follow-up to #5825, deferred from it on purpose. The wallet resume of an over-cap Built / Broadcast row without local finality is tracked separately in #5808.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions