-
Notifications
You must be signed in to change notification settings - Fork 5k
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
[Bug]: Zero-arg function calls shown as "Contract interaction" rather than function name #15837
Comments
Hi! Are your function signatures also registered with https://www.4byte.directory/ ? We recently had to disable fetching from the Parity registry because it was being griefed. It seems that those docs are out of date. |
@FrederikBolding no, sorry, I didn't know about that service -- I was just following the MetaMask docs. Thanks, I'll register there instead. Is this a permanent switch? |
PS @FrederikBolding how does MetaMask handle collisions? There are currently 327k registered signatures at 4byte.directory, which means one chance in 13,122 of a collision. Can you resolve any ambiguity that arises by filtering through the list of returned signatures, and at least eliminating all signatures that don't typecheck against the arguments that were sent with the function call? |
@FrederikBolding I have at least one 4byte.directory 4-byte function selector collision for my API, and 4byte.directory does not seem to allow alternatives to be registered for a given function selector, which means the first function name that is registered for a given function selector will forevermore be the only function name that will be shown by MetaMask for all different functions that have the same function selector. Would it be possible for MetaMask just to pull the API for verified contracts directly from Etherscan? |
This issue has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 45 days. Thank you for your contributions. |
This issue has been automatically marked as stale because it has not had recent activity in the last 90 days. It will be closed in 45 days if there is no further activity. The MetaMask team intends on reviewing this issue before close, and removing the stale label if it is still a bug. We welcome new comments on this issue. We do not intend on closing issues if they report bugs that are still reproducible. Thank you for your contributions. |
This issue was closed because there has been no follow up activity in the last 45 days. If you feel this was closed in error, please reopen and provide evidence on the latest release of the extension. Thank you for your contributions. |
Describe the bug
I have several functions registered with the Parity registry (verified by reading them back), as required by MetaMask for resolving function names.
If the function takes one or more arguments (e.g.
sell(uint256,uint256)
, the function name correctly shows in the MetaMask history (e.g. asSell
).However, if the function takes no arguments (e.g.
cancelOrder()
), the function name shows in the MetaMask history asContract interaction
. No attempt is made to show the function name (e.g. asCancel Order
).There seems to be an issue in the function signature parser, which takes the function signature string returned by the Parity registry, which does not like
()
as the parameter list.A StackExchange search indicates that others have run into the same problem.
Steps to reproduce
Error messages or log output
No response
Version
10.18.0
Build type
No response
Browser
Chrome
Operating system
Linux
Hardware wallet
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: