-
Notifications
You must be signed in to change notification settings - Fork 17
Update Codama to 1.2.4 and use Codama CLI #34
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
Conversation
This PR updates Codama and its renderers to the latest versions. It also uses the new Codama CLI to render the clients of the System program.
| solana-client = { version = "^2.1", optional = true } | ||
| solana-sdk = { version = "^2.1", optional = true } |
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.
Note that we are currently having to use these crates instead of the more granular ones to stay compatible with clients using Solana below 2.1.
We have documented a way forward on the Codama Rust renderer here.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
joncinque
left a comment
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 great, thanks for sharing!
| let accounts = rpc | ||
| .get_multiple_accounts(&addresses) | ||
| .map_err(|e| std::io::Error::new(std::io::ErrorKind::Other, e.to_string()))?; |
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.
Some RPCs meter the get_multiple_accounts call differently than the normal get_account_info, so it might be worth avoiding get_multiple_accounts for just one input
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.
Ah good to know. This is something that would needs updating on the Rust renderer (was introduced in this PR). I made an issue for it.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This PR updates Codama and its renderers to the latest versions.
It also uses the new Codama CLI to render the clients of the System program.