Repository navigation
fix(tasks): renew expired unused funding authorizations - #131
Closed
vapi-development wants to merge 2 commits into
Closed
vapi-development wants to merge 2 commits into
vapi-development wants to merge 2 commits into
Conversation
A signed V2 funding authorization that expired before it was used blocked every rerun of vapi task fund (v2_plan_mismatch on the elapsed window). Once vAPI abandons the hosted operation with proof expired-authorization, or USDC shows the nonce unused at a block past validBefore, the run releases that reservation and asks for a new signature under a fresh key. A recovered operation continues without signing again. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: vAPI Development <336934719+vapi-development@users.noreply.github.com>
Review repair: a saved create-pool transaction no longer keeps the expired funding authorization; abandonment names the operation's current step after recovering it; the chain proof reads a confirmed block and rechecks its hash; a scanning answer is polled; an interrupted signer takes the same proof path; legacy reservations without a task key are released. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: vAPI Development <336934719+vapi-development@users.noreply.github.com>
vapi-development
force-pushed
the
fix/expired-signed-funding-authorization
branch
from
December 3, 2026 15:48
9d2dcfb to
3f2088c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
vapi task fundon a V2 pool order: once a signed EIP-3009 funding authorization expired unused (the first run failed after signing, before funding), every rerun failed forever withv2_plan_mismatch(elapsed time window). Seen on Base mainnet 12-03 (order b9813077, pool 6).Cause
v2-execution.ts:journal.signedmade the run "started", and only an unstarted expired intent was renewed; the signed one always reachedverifyV2TypedData, which refuses the elapsed window.Fix
A signed (or reserved-but-interrupted) funding authorization with no saved
v2-fundtransaction is replaced only after proof that it can never move money:proof: "expired-authorization"; vAPI abandons only after a complete chain scan and a confirmed-block check that the authorization expired and its nonce is unused.recoveredcontinues without a new signature;scanningis polled, then stops with "nothing new was signed".authorizationStateread at a confirmed block pastvalidBefore, block hash rechecked.Then the old spend reservation is released (also legacy rows without a task key) and the run asks for a new authorization under a fresh key. A saved create-pool transaction no longer blocks this.
Tests
packages/core/src/tasks/v2-execution.test.ts: red first (15 failed on 0.17.4), 178 pass; core suite 2,627 pass (--testTimeout=15000; two unrelated swarm tests time out at 5 s under load); typecheck, lint, prettier, lint:copy, build pass.Review
Built by Codex (gpt-6.2-sol); cross-family review by Claude Opus: 2 blocking + 5 non-blocking → one repair → narrow re-review: all fixed, no new blocking finding.
follow-up: if the signature upload reached vAPI but its response was lost before the hosted operation id was saved locally, the chain proof still holds, but a hosted operation that keeps the slot can refuse the fresh prepare.
🤖 Generated with Claude Code