fix: failed requests reach the page with an error code and the node's data (closes #533) #565

Merged
clawbot merged 1 commits from issue-533-rpc-error-codes into next 2026-10-18 22:12:11 +02:00
1 Commits
Author SHA1 Message Date
sneak e2b50ad4a9 fix: failed requests reach the page with an error code and the node's data (closes #533)
check / check (push) Waiting to run
e2e / e2e-chrome (push) Waiting to run
e2e / e2e-firefox (push) Waiting to run
A page's request that the node refuses now reaches it with the node's
own JSON-RPC code and data: a proxied read such as a reverting eth_call,
a transaction whose gas estimate reverts, and a failed broadcast. Every
other refusal carries a code too: 4100 when there is no address, -32602
when the site asks for two different gas limits or a transaction type
this wallet does not sign, and -32603 for a failure inside the wallet.

nodeError() in approvalVerify.js reads the node's error out of what
ethers throws, as failureTexts() already did inline.

Model: opus-5-5
2026-10-18 18:41:10 +00:00