-
Notifications
You must be signed in to change notification settings - Fork 22
Add extension that emits erc20 events for etherscan visibility #75
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
base: master
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for confidential-tokens ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
2350116
to
e9268c7
Compare
*/ | ||
abstract contract ConfidentialFungibleTokenERC20Events is ConfidentialFungibleToken { | ||
function _update(address from, address to, euint64 amount) internal virtual override returns (euint64) { | ||
emit IERC20.Transfer(from, to, 1); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any reason to use 1 over something else ? I'd personally use 0. That way the arithmetics of inbound - outbound would always be 0, and can never go negative.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
0 value transfers are automatically hidden by Etherscan. Tried that first
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interesting, thank you for this test.
Considering what you say, I feel adding Transfer
events (with this dummy value of 1), might not be the best path for being compatible with Etherscan (since it looks a bit twisted).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't disagree but without any dedicated support from etherescan this is likely the only way. We could do something with ERC1155 or ERC721 too but I feel like that isn't desirable.
No description provided.