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
Just reviewing the code for the subgraph (if you don't mind me doing so), I noticed that:
https://github.com/oceanprotocol/ocean-subgraph/blob/main/src/mappings/pool.ts#L427 and https://github.com/oceanprotocol/ocean-subgraph/blob/main/src/mappings/pool.ts#L439 that it's using
event.params.(from|to).toHex()
This could be an issue if the user is using a smart contract to do the mint/burn/swap. As an example, look at this tx: https://etherscan.io/tx/0x09717991d7144b0c7ae61877ce3e25f2c44af752fa3d7fa8166ff3073cb95286
The correct attribution should be the original user that minted/burned the LP token, not the contract.
If you'd like, I can make a PR to address this!
The text was updated successfully, but these errors were encountered:
By the way we noticed this when we were developing https://apy.vision and we also had this logic initially but realized that this wouldn't work with smart contract interactions :)
Sorry, something went wrong.
thanks for pointing that out
This sounds like a cool idea.
Go for it! We'd like that. :) :)
alexcos20
No branches or pull requests
Just reviewing the code for the subgraph (if you don't mind me doing so), I noticed that:
https://github.com/oceanprotocol/ocean-subgraph/blob/main/src/mappings/pool.ts#L427 and https://github.com/oceanprotocol/ocean-subgraph/blob/main/src/mappings/pool.ts#L439 that it's using
event.params.(from|to).toHex()This could be an issue if the user is using a smart contract to do the mint/burn/swap. As an example, look at this tx: https://etherscan.io/tx/0x09717991d7144b0c7ae61877ce3e25f2c44af752fa3d7fa8166ff3073cb95286
The correct attribution should be the original user that minted/burned the LP token, not the contract.
If you'd like, I can make a PR to address this!
The text was updated successfully, but these errors were encountered: