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.
When working with the gas relayer, we receive a signed transaction hash that was signed by the "unknown" paymaster. In my case, this paymaster was not funded. I needed to extract the sender to fund the account. This utility method might be useful in the future.
Problems
Although this unit test demonstrates the
viem
implementation agrees withethers
. It doesn't agree with what someone else got (in CA Telegram). In fact, trying to relay this transaction witheth_sendRawTransaction
resulted in an "INSUFFICIENT_FUNDS" error -- even after the public key of this was extracted.Note that, from the
signedTxHash:
0x02f872611c847735940085174876e800825208940c0a71335cc50b821570f6f8b302b248d0e56ed4870eebe0b40e800080c080a0d490e3ce4e974cae1f89c4b328bf4dc7ecba7b1cef9838be6282ca92fd5a8127a01c032f8bfa93bd48fb5215813e4f3a21f8e5da015ebd52b4daa945bcc2d4749e
we recover
Incorrect Sender:
0x909BaB1A50EBd17c0E771b8B0BF2A95fEB34B205
While someone else got
Correct Sender:
0x993944ce7ed881a353b7e34f63a37242041629fb
.The "correctness" is concluded by the following observation: Funding the
0x909...
account still resulted inINSUFFICIENT_FUNDS
, while funding0x993
resulted in a successful tx with:txHash:
0x2da68d8765521fdbb331d2696cf51e4bab0ca37e21161350f7f03ec35eb8a540
.Unfortunately
eth_getTransactionReceipt
, but saysAlready Exists
when trying to resubmit the transaction.Relevant RPC Requests
Send Signed Transaction
Get Transaction Receipt
According to this online tool:
https://rawtxdecode.in/ the sender is different.
and this rust implementation: https://github.com/near/multichain-gas-station-contract/blob/master/gas_station/tests/tests.rs#L515