-
Notifications
You must be signed in to change notification settings - Fork 293
Updated Documentation for Rust SDK Compatibility with Solana SDK v2 #751
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
Updated Documentation for Rust SDK Compatibility with Solana SDK v2 #751
Conversation
docs/rust/README.md
Outdated
| ### 1. High-Level SDK, compatible with Solana SDK versions `^1.18.0` but `<2.0.0` | ||
| ### 1. High-Level SDK | ||
| #### Compatibility | ||
| - Compatible with Solana SDK versions `^1.18.0` but `<3.0.0`. By default, the Rust compiler will install the latest version of Solana SDK `^v2`. This can cause dependcy issues when using older versions. To solve this you can apply a lockfile patch with the following command: |
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.
Rust compiler -> cargo
docs/rust/README.md
Outdated
| #### Compatibility | ||
| - Compatible with Solana SDK versions `^1.18.0` but `<3.0.0`. By default, the Rust compiler will install the latest version of Solana SDK `^v2`. This can cause dependcy issues when using older versions. To solve this you can apply a lockfile patch with the following command: | ||
| ```bash | ||
| cargo update solana-program:<current-version> --precise <required-version> |
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.
This one is kinda tricky cause you potentially also need to patch solana-sdk, solana-client, solana-account-decoder, spl-token, spl-memo, spl-token-2022, and spl-associated-token-account
docs/rust/README.md
Outdated
| ### 3. Low-Level SDK, compatible with Solana SDK versions `^1.16.0` but `<2.0.0` | ||
| ### 3. Low-Level SDK | ||
| #### Compatibility | ||
| - Compatible with `anchor v0.29.0`. If you enable the `anchor` feature of `orcah_whirlpools_client` in `cargo.toml` while using a different version of anchor in your project, you may need to apply a lockfile patch to resolve dependency conflicts: |
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.
Believe it is 0.26 to 0.29
docs/rust/README.md
Outdated
| ### 3. Low-Level SDK, compatible with Solana SDK versions `^1.16.0` but `<2.0.0` | ||
| ### 3. Low-Level SDK | ||
| #### Compatibility | ||
| - Compatible with `anchor v0.29.0`. If you enable the `anchor` feature of `orcah_whirlpools_client` in `cargo.toml` while using a different version of anchor in your project, you may need to apply a lockfile patch to resolve dependency conflicts: |
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.
*orcah
docs/rust/README.md
Outdated
| ### 3. Low-Level SDK, compatible with Solana SDK versions `^1.16.0` but `<2.0.0` | ||
| ### 3. Low-Level SDK | ||
| #### Compatibility | ||
| - Compatible with `anchor v0.29.0`. If you enable the `anchor` feature of `orcah_whirlpools_client` in `cargo.toml` while using a different version of anchor in your project, you may need to apply a lockfile patch to resolve dependency conflicts: |
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.
Lockfile patch is to switch to a lower version of anchor
This PR updates the documentation to reflect recent changes in the Rust SDK, ensuring compatibility with Solana SDK v2. The updates clarify dependency management for both the high-level and low-level SDKs, including how to handle potential version conflicts with
solana-programandanchor.Example

Example
