-
Notifications
You must be signed in to change notification settings - Fork 335
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
Xtokens smart contract selector fix and test #898
Xtokens smart contract selector fix and test #898
Conversation
…ts + test web3 data
… into xtokens_smart_contract_selector_fix_and_test
… into xtokens_smart_contract_selector_fix_and_test
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.
Looks good! I need more information/descriptions about what is going on there
The selectors were wrong because they were not using the struct type (u8, bytes[]). However we did not catch that because we were not testing this through a true solidity call. These tests fix that by compiling an instance of the precompiles contract and using the selectors gotten by ethers.js itself. If the selectors are wrong, the calls do not pass. If the selectors are correct, the call passes and the extrinsic is dispatched |
… into xtokens_smart_contract_selector_fix_and_test
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.
Looks good :)
…tract_selector_fix_and_test
What does it do?
It fixes the selector and adds typescript tests with ether.js to ensure the encoding is correctly done
What important points reviewers should know?
Is there something left for follow-up PRs?
What alternative implementations were considered?
Are there relevant PRs or issues in other repositories (Substrate, Polkadot, Frontier, Cumulus)?
What value does it bring to the blockchain users?