-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cast run
does not decode calldata for library (delegate-)call.
#5950
Comments
For anyone facing the same issue, the manual workaround I did is:
This is a bit of a pain though (especially step 2) and took me > 1 hour to get right, so definetely would be great to find a workaround inside cast for this. |
After revisiting this I noticed that we seem to use exclusively the Returns |
Opened an issue on openchain repo to see if their service can be extended to be able to decode these types of signatures: |
Able to reproduce with given setup For future reference
|
Component
Cast
Have you ensured that all of these are up to date?
What version of Foundry are you on?
cast 0.2.0 (96ab913 2023-09-28T00:20:52.150553000Z)
What command(s) is the bug in?
cast run
Operating System
macOS (Apple Silicon)
Describe the bug
When running
cast run
on a transaction that includes delegatecalls to a library deployment, those calls are not decoded correctly in the transaction traces, even though the libraries source code is verified on etherscan.When running
cast run --rpc-url <ETH_MAINNET_RPC_URL> --quick 0x07a6ad95d76f4c1318d38564439347b39a47b126a7cbd3fe0b58a980392d4a35
the delegate calls are shown as:Whereas I'd expect them to be decoded using the library's abi. (In above case it would be the
swapExactTokensForTokens(DEXAdapter.Addresses,uint256,uint256,DEXAdapter.SwapData)
selector.Note that I haven't verified this behaviour for other library deployments yet, so it could be caused by something in this specific signature / example as well.
The text was updated successfully, but these errors were encountered: