-
Notifications
You must be signed in to change notification settings - Fork 15
Open
Description
Description
When a transaction fails gas estimation (e.g., would revert onchain), rrelayer does not mark it as FAILED. Instead, the transaction remains
in PENDING status and the pending queue worker retries indefinitely, causing an infinite retry loop.
Steps to Reproduce
- Submit a transaction via rrelayer API that would revert onchain (e.g., to a non-existent contract address)
- Transaction is queued with status PENDING
- rrelayer's background worker attempts to send the transaction
- Gas estimation fails with error:
Gas calculation error - Transaction remains PENDING instead of being marked FAILED
- Worker continuously retries every few seconds
Expected Behavior
- Transactions that fail gas estimation should be marked as FAILED after N retry attempts
- Failed transactions should not be retried indefinitely
- Error should be surfaced to the API caller
Actual Behavior
- Transaction stays PENDING forever
- Logs show continuous retry attempts:
INFO Preparing to send transaction for relayer with speed FAST
ERROR PENDING QUEUE ERROR: Send transaction error: Gas calculation error
INFO Preparing to send transaction for relayer with speed FAST
ERROR PENDING QUEUE ERROR: Send transaction error: Gas calculation error - Restarting rrelayer doesn't help (transactions are persisted in PostgreSQL)
- Only workaround is to manually delete pending transactions or reset database
Logs
INFO Sending transaction Transaction { id: TransactionId(...), status: PENDING, ... }
INFO Computing gas price for transaction with speed FAST
ERROR PENDING QUEUE ERROR: Send transaction error: Gas calculation error
After N attempt, transaction should fail, and set to Failed state. This might not be a big deal, however since we are using Turnkey, this adds up to a bit. Thanks.
Metadata
Metadata
Assignees
Labels
No labels