Skip to content

Bumping client to solana 3.0 - #178

Merged
blockiosaurus merged 7 commits into
mainfrom
feat/solana-3-client
Nov 13, 2025
Merged

Bumping client to solana 3.0#178
blockiosaurus merged 7 commits into
mainfrom
feat/solana-3-client

Conversation

@blockiosaurus

Copy link
Copy Markdown
Contributor

Fixes #177

@blockiosaurus
blockiosaurus requested a review from danenbm November 7, 2025 13:45
@vercel

vercel Bot commented Nov 7, 2025

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
mpl-token-metadata-js-docs Ready Ready Preview Comment Nov 13, 2025 5:25pm

@coderabbitai

coderabbitai Bot commented Nov 7, 2025

Copy link
Copy Markdown

Summary by CodeRabbit

  • Bug Fixes

    • Improved error handling for deserialization operations with consistent error types across token-related structures.
  • Documentation

    • Added comprehensive development and architecture guide for contributors.
  • Chores

    • Updated development environment (Node.js 22.x, Rust 1.85.1, Solana 3.0.0).
    • Updated package manager to pnpm 8.9.0.

Walkthrough

This pull request updates the project to support Solana SDK 3.0+ versions by upgrading core dependencies (borsh, solana-program, SPL Token 2022), migrating to interface crate variants, standardizing error types in trait implementations, and updating build infrastructure and package managers accordingly.

Changes

Cohort / File(s) Change Summary
Dependency Version Updates
clients/rust/Cargo.toml
Upgraded borsh to 1.0, solana-program to 3.0, and SPL Token ecosystem crates to 3.0+; added new interface crates (spl-token-2022-interface, solana-system-interface, solana-pubkey); removed version ranges in favor of fixed versions.
Package Manager Configuration
package.json, clients/js/package.json
Updated @metaplex-foundation/kinobi from ^0.17.0 to 1.0.0-alpha.0; upgraded prettier from ^2.5.1 to ^3.2.5; bumped pnpm from 8.2.0 to 8.9.0 across both files.
Error Type Standardization
clients/rust/src/traits.rs
Fixed deserialization error types in safe_deserialize implementations across CollectionAuthorityRecord, MasterEdition, MetadataDelegateRecord, and Metadata; replaced borsh::maybestd::io::Error with borsh::io::Error for consistency.
SPL Token 2022 Interface Migration
clients/rust/tests/create.rs, clients/rust/tests/lock.rs, clients/rust/tests/mint.rs, clients/rust/tests/setup/digital_asset.rs, clients/rust/tests/setup/mod.rs, clients/rust/tests/setup/token_manager.rs
Migrated imports and references from spl_token_2022 to spl_token_2022_interface crate for ExtensionType, state Account, and program IDs; updated system program references to solana_system_interface; replaced Pubkey imports with solana_pubkey variants.
Keypair Construction Refactor
clients/rust/tests/setup/dirty_clone.rs
Replaced Keypair cloning via serialization/deserialization with new_from_array constructor using secret_bytes directly, eliminating unwrap-based panic path.
Build Infrastructure Updates
.github/.env, .github/workflows/build-rust-client.yml, .github/workflows/test-rust-client.yml
Added RUST_CLIENT_VERSION=1.85.1 and SOLANA_CLIENT_VERSION=3.0.0; updated workflow environment variable references from RUST_VERSION/SOLANA_VERSION to RUST_CLIENT_VERSION/SOLANA_CLIENT_VERSION; bumped NODE_VERSION from 16.x to 22.x.
Project Documentation
CLAUDE.md
Added new root-level documentation file covering repository overview, program ID, development commands, code generation workflow, validator usage, and project architecture guidance.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

  • Attention areas:
    • clients/rust/src/traits.rs: Verify that the error type change from borsh::maybestd::io::Error to borsh::io::Error is compatible across all deserialization paths and does not impact downstream error handling.
    • clients/rust/Cargo.toml: Confirm dependency version compatibility, especially the new interface crates (spl-token-2022-interface, solana-system-interface, solana-pubkey) with the existing codebase.
    • clients/rust/tests/setup/token_manager.rs: Review the instruction path migration from spl_token_2022::instruction to spl_token_2022_interface::instruction to ensure all token operations remain functionally equivalent.
    • clients/rust/tests/setup/dirty_clone.rs: Validate that Keypair::new_from_array is the correct stable API and produces equivalent results to the prior serialization round-trip.

Possibly related PRs

  • Add upper limit to rust client #176: Updates Solana SDK dependency constraints in clients/rust/Cargo.toml; addresses related version alignment concerns for solana-program and SPL ecosystem crates.

Suggested reviewers

  • danenbm
  • brandontulsi

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Out of Scope Changes check ⚠️ Warning While most changes align with Solana 3.0 migration, the addition of CLAUDE.md documentation file and prettier dependency bump appear unrelated to the primary objective of updating Solana SDKs. Consider removing CLAUDE.md and the prettier version bump from this PR, or create separate PRs for these unrelated changes to maintain focus on the Solana 3.0 migration objective.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title 'Bumping client to solana 3.0' clearly and specifically describes the main change—updating Solana SDK dependencies to version 3.0, which aligns with the changeset modifications.
Description check ✅ Passed The description 'Fixes #177' is related to the changeset as it directly references the linked issue about updating to Solana SDKs 3+ versions, which the PR implements.
Linked Issues check ✅ Passed The PR successfully addresses the linked issue #177 by updating Rust and JS client dependencies to Solana SDK 3.0 versions, updating dependency paths, workflow configurations, and environment variables to support the newer ecosystem.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/solana-3-client

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 298c6fc and 17ca949.

⛔ Files ignored due to path filters (1)
  • clients/js/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (1)
  • clients/js/package.json (2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
  • GitHub Check: Generate clients
  • GitHub Check: Programs / Test (token-metadata)
🔇 Additional comments (3)
clients/js/package.json (3)

46-46: Clarify necessity of tooling updates relative to Solana 3.0 migration.

The PR objective is to support Solana SDK 3.0+. These devDependency and packageManager updates appear to be tooling maintenance rather than direct dependencies of the Solana migration. Confirm that:

  • These updates are necessary prerequisites for the Solana 3.0 migration
  • OR, if they are independent maintenance updates, they should be separated into a distinct PR for clarity

Also applies to: 63-63


46-46: I need to verify one more critical aspect before finalizing the review comment.

Verify prettier 3.x upgrade compatibility and test formatting changes.

Prettier 3.0 introduced several breaking changes from 2.x, most notably the default trailingComma changed from "es5" to "all". This will alter code formatting across the codebase. Before merging, ensure:

  • Run format scripts locally (npm run format:fix) and verify no unexpected formatting changes occur to source files
  • Check CI/CD pipeline—the format and lint checks must pass
  • Confirm eslint-config-prettier@^8.5.0 remains compatible with prettier 3.2.5 (consider checking for or updating to a more recent version of eslint-config-prettier if compatibility issues arise)
  • Test the pre-commit hooks and any formatter integrations with the new version

63-63: Confirmed: pnpm 8.9.0 is a stable, published release with intentional improvements over 8.2.0.

pnpm 8.9.0 is published as a stable release on the npm registry. Key changes from 8.2.0 include reflinks as the default on macOS and Windows Dev Drives (replacing hard links), improved peer-deps resolution to avoid OOM, and merged pnpm.overrides/Yarn resolutions. These are documented improvements rather than unexpected changes. Consider testing the reflinks behavior in your development environment to ensure compatibility with your toolchain and lockfile, though no breaking changes are indicated.


Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
clients/rust/tests/setup/digital_asset.rs (1)

189-239: Consider parameterizing the token program ID.

Line 228 hard-codes spl_token_2022_interface::ID, but other methods in this file (e.g., create, create_default) accept spl_token_program as a parameter. Consider accepting the token program as a parameter for consistency, or document why this method specifically requires Token-2022.

Apply this diff to parameterize the token program:

 pub async fn create_default_with_mint_extensions(
     &mut self,
     context: &mut ProgramTestContext,
     token_standard: TokenStandard,
     extensions: &[ExtensionType],
+    spl_token_program: Pubkey,
 ) -> Result<(), BanksClientError> {
     // ... existing code ...
-    .spl_token_program(Some(spl_token_2022_interface::ID))
+    .spl_token_program(Some(spl_token_program))
     .instruction();
clients/rust/src/traits.rs (1)

164-204: Ensure consistent error type across safe_deserialize implementations (line 164).

TokenRecord::safe_deserialize returns Result<TokenRecord, Error> (std::io::Error) while Metadata and other implementations use borsh::io::Error. For consistency, update line 164 to use borsh::io::Error:

pub fn safe_deserialize(data: &[u8]) -> Result<TokenRecord, borsh::io::Error> {
📜 Review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a7ee5e1 and aff3371.

⛔ Files ignored due to path filters (160)
  • clients/js/src/generated/types/collectionDetailsToggle.ts is excluded by !**/generated/**
  • clients/rust/Cargo.lock is excluded by !**/*.lock
  • clients/rust/src/generated/accounts/collection_authority_record.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/deprecated_master_edition_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/edition.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/edition_marker.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/edition_marker_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/holder_delegate_record.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/master_edition.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/metadata.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/metadata_delegate_record.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/token_owned_escrow.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/token_record.rs is excluded by !**/generated/**
  • clients/rust/src/generated/accounts/use_authority_record.rs is excluded by !**/generated/**
  • clients/rust/src/generated/errors/mpl_token_metadata.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/approve_collection_authority.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/approve_use_authority.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/bubblegum_set_collection_size.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/burn.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/burn_edition_nft.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/burn_nft.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/burn_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/close_accounts.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/close_escrow_account.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/collect.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/convert_master_edition_v1_to_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/create.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/create_escrow_account.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/create_master_edition_v3.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/create_metadata_account_v3.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/create_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_authority_item_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_collection_item_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_collection_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_data_item_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_data_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_locked_transfer_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_print_delegate_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_programmable_config_item_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_programmable_config_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_sale_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_staking_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_standard_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_transfer_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/delegate_utility_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/deprecated_mint_new_edition_from_master_edition_via_printing_token.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/freeze_delegated_account.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/lock.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/lock_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/migrate.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/mint.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/mint_new_edition_from_master_edition_via_token.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/mint_new_edition_from_master_edition_via_vault_proxy.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/mint_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/print.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/print_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/print_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/puff_metadata.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/remove_creator_verification.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/resize.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_authority_item_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_collection_authority.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_collection_item_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_collection_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_data_item_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_data_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_locked_transfer_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_migration_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_print_delegate_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_programmable_config_item_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_programmable_config_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_sale_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_staking_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_standard_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_transfer_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_use_authority.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/revoke_utility_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/set_and_verify_collection.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/set_and_verify_sized_collection_item.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/set_collection_size.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/set_token_standard.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/sign_metadata.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/thaw_delegated_account.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/transfer.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/transfer_out_of_escrow.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/transfer_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/unlock.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/unlock_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/unverify.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/unverify_collection.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/unverify_collection_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/unverify_creator_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/unverify_sized_collection_item.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_as_authority_item_delegate_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_as_collection_delegate_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_as_collection_item_delegate_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_as_data_delegate_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_as_data_item_delegate_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_as_programmable_config_delegate_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_as_programmable_config_item_delegate_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_as_update_authority_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_metadata_account_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_primary_sale_happened_via_token.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/update_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/use.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/use_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/utilize.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/verify.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/verify_collection.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/verify_collection_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/verify_creator_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/instructions/verify_sized_collection_item.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/authority_type.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/authorization_data.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/burn_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/collection.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/collection_details.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/collection_details_toggle.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/collection_toggle.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/create_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/creator.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/data.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/data_v2.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/delegate_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/escrow_authority.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/holder_delegate_role.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/key.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/lock_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/metadata_delegate_role.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/migration_type.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/mint_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/mint_new_edition_from_master_edition_via_token_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/payload.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/payload_key.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/payload_type.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/print_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/print_supply.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/programmable_config.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/proof_info.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/reservation.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/reservation_v1.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/revoke_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/rule_set_toggle.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/seeds_vec.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/set_collection_size_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/token_delegate_role.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/token_standard.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/token_state.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/transfer_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/unlock_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/update_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/use_args.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/use_method.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/uses.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/uses_toggle.rs is excluded by !**/generated/**
  • clients/rust/src/generated/types/verification_args.rs is excluded by !**/generated/**
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (10)
  • clients/rust/Cargo.toml (1 hunks)
  • clients/rust/src/traits.rs (4 hunks)
  • clients/rust/tests/create.rs (11 hunks)
  • clients/rust/tests/lock.rs (1 hunks)
  • clients/rust/tests/mint.rs (6 hunks)
  • clients/rust/tests/setup/digital_asset.rs (2 hunks)
  • clients/rust/tests/setup/dirty_clone.rs (1 hunks)
  • clients/rust/tests/setup/mod.rs (2 hunks)
  • clients/rust/tests/setup/token_manager.rs (11 hunks)
  • package.json (1 hunks)
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-08-08T13:31:39.530Z
Learnt from: mcintyre94
Repo: metaplex-foundation/mpl-token-metadata PR: 175
File: configs/codama.cjs:218-221
Timestamp: 2025-08-08T13:31:39.530Z
Learning: In mpl-token-metadata configs (configs/codama.cjs and configs/kinobi.cjs), when selecting instruction accounts for defaults, use the grouped, fully anchored regex /^(edition|masterEdition)$/ to match only the exact account names and avoid accidental matches like editionMarker.

Applied to files:

  • clients/rust/tests/setup/token_manager.rs
🧬 Code graph analysis (5)
clients/rust/tests/setup/digital_asset.rs (1)
clients/rust/tests/setup/token_manager.rs (3)
  • ExtensionType (62-62)
  • ExtensionType (205-205)
  • ExtensionType (260-260)
clients/rust/tests/mint.rs (3)
clients/rust/tests/setup/token_manager.rs (3)
  • ExtensionType (62-62)
  • ExtensionType (205-205)
  • ExtensionType (260-260)
clients/rust/tests/setup/digital_asset.rs (1)
  • mint (75-113)
clients/rust/tests/setup/mod.rs (1)
  • get_account (24-31)
clients/rust/tests/create.rs (1)
clients/rust/tests/setup/token_manager.rs (3)
  • ExtensionType (62-62)
  • ExtensionType (205-205)
  • ExtensionType (260-260)
clients/rust/tests/setup/token_manager.rs (2)
clients/rust/src/generated/instructions/create.rs (4)
  • instruction (37-42)
  • instruction (259-280)
  • spl_token_program (228-234)
  • spl_token_program (588-594)
clients/rust/src/generated/instructions/create_v1.rs (4)
  • instruction (43-48)
  • instruction (371-411)
  • spl_token_program (264-270)
  • spl_token_program (732-738)
clients/rust/src/traits.rs (1)
programs/token-metadata/program/src/state/metadata.rs (1)
  • deserialize (354-357)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Programs / Build
🔇 Additional comments (23)
package.json (2)

25-25: pnpm version bump is safe and appropriate.

The patch-level upgrade from 8.2.0 to 8.9.0 is a safe update within the stable pnpm 8.x line. This aligns with the broader tooling refresh for the Solana 3.0 migration.


21-21: The version @metaplex-foundation/kinobi@1.0.0-alpha.0 does exist in the npm registry and was published yesterday. It includes proper dependencies for Solana SDK 3.0 support (notably @solana/codecs-strings: 2.0.0-preview.1). The original review comment's concern about version non-existence is unfounded, and this update is a valid part of the Solana 3.0 migration.

Likely an incorrect or invalid review comment.

clients/rust/src/traits.rs (3)

32-46: LGTM! Error type standardization aligns with Borsh 1.0.

The macro correctly updates the return type to borsh::io::Error, which is the standard error type in Borsh 1.0 (previously borsh::maybestd::io::Error in earlier versions). This change applies consistently to all macro-generated implementations.


80-89: LGTM! Metadata deserialization updated consistently.

The safe_deserialize method correctly updates error types to borsh::io::Error and maintains the existing validation logic (key matching, data emptiness checks).


91-156: LGTM! Deserialization error handling preserved.

The deserialize_unchecked method consistently updates all error types to borsh::io::Error while preserving the existing fallback behavior for handling corrupted metadata fields (V1.2 and V1.3 extensions).

clients/rust/tests/setup/digital_asset.rs (1)

12-12: LGTM! Import updated to interface crate.

The import path correctly updates from spl_token_2022::extension::ExtensionType to spl_token_2022_interface::extension::ExtensionType, aligning with the Solana 3.0 migration.

clients/rust/tests/lock.rs (1)

16-21: LGTM! Test updated to use interface crate.

The import and test parameterization correctly migrate to spl_token_2022_interface, maintaining test coverage for both token programs.

clients/rust/tests/setup/mod.rs (1)

7-17: LGTM! Test infrastructure updated to interface crate.

The imports and program registration correctly migrate to spl_token_2022_interface, ensuring the test environment uses the updated dependencies.

clients/rust/tests/setup/token_manager.rs (6)

2-19: LGTM! Imports migrated to interface crates.

All token-related imports correctly updated from spl_token_2022 to spl_token_2022_interface, including extension types, instructions, and state types. This aligns with the Solana 3.0 migration strategy.


68-74: LGTM! Account creation migrated to system interface.

The create_account instruction correctly uses solana_system_interface::instruction::create_account, aligning with the interface-based architecture in Solana 3.0.


174-182: LGTM! Mint initialization uses interface crate.

The initialize_mint2 instruction correctly migrated to spl_token_2022_interface::instruction, maintaining consistency with the broader migration.


194-250: LGTM! Token account creation migrated consistently.

Lines 202, 224, 233 correctly use spl_token_2022_interface for program ID checks and instruction calls (initialize_immutable_owner, initialize_account3), ensuring consistent interface usage.


252-303: LGTM! Extension-based token account creation updated.

Lines 265, 275, 284 consistently use the interface crate for account creation and initialization instructions, properly handling token accounts with extensions.


25-31: No breaking changes detected—the default is appropriate for extension operations.

The verification shows that both TokenManager::default() usages (mint.rs:297 and digital_asset.rs:198) are in extension-specific methods that require Token-2022 functionality. Tests requiring spl_token::ID explicitly construct TokenManager { spl_token_program } (as seen in mint.rs:90), so they are not affected by this default change. The TokenManager logic already handles both token programs conditionally.

clients/rust/tests/setup/dirty_clone.rs (1)

8-10: LGTM! Improved keypair cloning implementation.

The change from from_bytes(&self.to_bytes()).unwrap() to new_from_array(*self.secret_bytes()) is more direct, efficient, and removes a potential panic point. This aligns with solana-sdk 3.0's API improvements.

clients/rust/tests/mint.rs (4)

7-10: LGTM! Imports updated for Solana 3.0 modularization.

The imports correctly migrate to the new crate structure:

  • Pubkey now comes from the dedicated solana_pubkey crate
  • Token types use spl_token_2022_interface

This aligns with Solana 3.0's modular architecture.


16-60: LGTM! Test cases updated consistently.

Lines 17, 19, 21, 23 correctly update test parameterization to use spl_token_2022_interface::ID, maintaining coverage for both token programs across all token standards.


62-127: LGTM! Test coverage maintained for both token programs.

Lines 63, 65, 67, 69 consistently update test cases to use spl_token_2022_interface::ID, ensuring both spl_token::ID and spl_token_2022_interface::ID are tested across all scenarios.


130-336: LGTM! Token-2022 specific tests updated correctly.

Lines 166, 174, 212, 220, 258, 266, 318-325, 332 correctly use spl_token_2022_interface::ID in Token-2022-specific test scenarios (mint_token2022 module), maintaining appropriate test isolation and coverage.

clients/rust/tests/create.rs (4)

228-228: Systematic and complete migration of Token-2022 ownership assertions.

All eight account owner assertions in the create_token2022 module have been consistently updated to use spl_token_2022_interface::ID. This ensures proper validation of Token-2022 mint extensions under the Solana 3.0 interface pattern.

Also applies to: 260-260, 315-315, 372-372, 404-404, 459-459, 514-514, 571-571


164-165: No issues found. Code is correct and consistent.

The use of solana_program::sysvar::instructions::ID at line 165 is correct and consistent with the codebase. Unlike system_program which has a solana_system_interface equivalent, there is no parallel interface crate for sysvar instructions. The established pattern throughout the codebase uses solana_program::sysvar::instructions::ID, and line 165 follows this correctly.


29-36: No issues found - test coverage changes are correct.

The test cases properly reference spl_token_2022_interface::ID, which is the correct way to obtain the Token-2022 program ID from the interface crate used in this test suite. All usages are consistent across test registration, assertions, and test parameters.


11-11: ExtensionType API compatibility verified—no issues found.

The migration to spl_token_2022_interface is correct and complete:

  • spl-token-2022-interface v2.0.0 is properly declared in [dev-dependencies] of clients/rust/Cargo.toml
  • Import at line 11 is correct and active
  • ExtensionType::try_calculate_account_len method is fully functional with both Mint and Account types
  • All extension variants are accessible throughout the test suite
  • No conflicting imports remain in the file

The code changes are verified as correct.

Comment thread clients/rust/Cargo.toml Outdated

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

📜 Review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between aff3371 and b4f134e.

📒 Files selected for processing (4)
  • .github/.env (1 hunks)
  • .github/workflows/build-rust-client.yml (1 hunks)
  • .github/workflows/test-rust-client.yml (1 hunks)
  • CLAUDE.md (1 hunks)
🧰 Additional context used
🪛 dotenv-linter (4.0.0)
.github/.env

[warning] 7-7: [UnorderedKey] The RUST_CLIENT_VERSION key should go before the RUST_VERSION key

(UnorderedKey)


[warning] 8-8: [UnorderedKey] The SOLANA_CLIENT_VERSION key should go before the SOLANA_CLI_VERSION key

(UnorderedKey)

🪛 markdownlint-cli2 (0.18.1)
CLAUDE.md

13-13: Headings should be surrounded by blank lines
Expected: 1; Actual: 0; Below

(MD022, blanks-around-headings)


14-14: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


21-21: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


23-23: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


27-27: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


32-32: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


39-39: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


41-41: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


45-45: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


50-50: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


56-56: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


58-58: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


63-63: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


65-65: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


67-67: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


72-72: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


79-79: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


81-81: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


85-85: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


87-87: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


91-91: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


98-98: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


100-100: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


104-104: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


109-109: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


114-114: Fenced code blocks should be surrounded by blank lines

(MD031, blanks-around-fences)


122-122: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (5)
  • GitHub Check: JS Client / Test (18.x)
  • GitHub Check: Rust Client / Build
  • GitHub Check: Rust Client / Test
  • GitHub Check: JS Client / Test (16.x)
  • GitHub Check: Programs / Test (token-metadata)
🔇 Additional comments (2)
.github/workflows/build-rust-client.yml (1)

43-48: Variable references correctly updated to new client versions.

The workflow now properly references the new RUST_CLIENT_VERSION and SOLANA_CLIENT_VERSION environment variables, which enables version management from the centralized .env file while maintaining manual override capability via inputs.

Note that the workflow_dispatch default inputs (lines 14, 19) specify older versions (1.68.0, 1.16.8) than the env vars (1.79.0, 3.0.0). Please confirm this is intentional—allowing manual testing against older toolchains—or if the defaults should be updated to match the env var versions for consistency.

.github/workflows/test-rust-client.yml (1)

29-34: Client-specific version variables properly updated.

The test workflow correctly references the new RUST_CLIENT_VERSION and SOLANA_CLIENT_VERSION environment variables, aligning it with the build workflow and ensuring consistent toolchain/SDK versions across the CI pipeline.

Comment thread .github/.env Outdated
Comment thread CLAUDE.md
danenbm
danenbm previously approved these changes Nov 13, 2025

@danenbm danenbm left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looked at every file LGTM!!!! thank you for doing this

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between e195daa and 13dd303.

⛔ Files ignored due to path filters (2)
  • clients/js/pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
  • clients/js/src/generated/types/collectionDetailsToggle.ts is excluded by !**/generated/**
📒 Files selected for processing (2)
  • clients/js/package.json (2 hunks)
  • package.json (1 hunks)
🔇 Additional comments (3)
clients/js/package.json (2)

63-63: Verify pnpm@8.9.0 availability and compatibility.

The packageManager was bumped from pnpm@8.2.0 to pnpm@8.9.0. Ensure this version exists and is compatible with your build and CI/CD infrastructure.


46-46: No issues found with prettier exact version pinning.

Version 2.5.1 is available on npm, so the exact version constraint is valid. The tighter pinning to "2.5.1" improves reproducibility without risk of unavailability.

package.json (1)

25-25: pnpm version bump is consistent with clients/js/package.json.

The packageManager was updated from pnpm@8.2.0 to pnpm@8.9.0, mirroring the change in clients/js/package.json. This is standard maintenance and ensures consistent tooling across the monorepo.

Comment thread package.json

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 9609ff4 and e85e9e0.

📒 Files selected for processing (1)
  • .github/workflows/main.yml (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
  • GitHub Check: Generate clients
  • GitHub Check: Programs / Test (token-metadata)

Comment thread .github/workflows/main.yml Outdated
@blockiosaurus
blockiosaurus merged commit c84a1ad into main Nov 13, 2025
12 checks passed
@blockiosaurus
blockiosaurus deleted the feat/solana-3-client branch November 13, 2025 17:48
@coderabbitai coderabbitai Bot mentioned this pull request Jan 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update to Solana sdks 3+ versions

2 participants