-
Notifications
You must be signed in to change notification settings - Fork 127
Abi Generation V2 #1459
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
Abi Generation V2 #1459
Conversation
Signed-off-by: aaronbuchwald <aaron.buchwald56@gmail.com>
abi/README.md
Outdated
- Built-in types include Address and Bytes. | ||
|
||
## Code Generation | ||
Use cmd/abigen to automatically generate Go structs from JSON. No newline at end of file |
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.
Can we add instructions instead of saying that this is handled by cmd/abigen
?
abi/README.md
Outdated
- JSON files should align with their corresponding .hex files. | ||
|
||
## Hash verification | ||
Wallets use ABI to display proper action names and field names. To verify ABI implementation in other languages, marshal the ABI into binary, hash it, and compare with the known hash. |
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.
Could you explain why?
abi/README.md
Outdated
To create an implementation of this package in any other langauge: | ||
- Copy the testdata folder. | ||
- Ensure all marshaling is identical to the Go implementation. | ||
- JSON files should align with their corresponding .hex files. |
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.
Let's add a little more detail here. Could we explain the structure of the testdata folder and how an implementation should use it to ensure compliance?
A clean version of #1301
Generate a JSON representation of all VM actions and their fields.
This includes all commits from #1198, so it should be merged after that.
When reviewing the code, please compare it with the code in PR 1198, not with the main branch.