github solana-foundation/solana-go v2.2.0
v2.2.0 — v1.25.0 parity: on-chain encoding fixes & confidential extension clients

5 hours ago

Brings the v2 line up to parity with v1.25.0, plus the ConfidentialMintBurn / ConfidentialTransferFee client API that landed on main after that tag. No module-path or Go-version changes since v2.1.0 — upgrading needs no code edits.

Install

go get github.com/solana-foundation/solana-go/v2@v2.2.0

Requires Go 1.25 or later (unchanged from v2.1.0).

  • Confidential mint-burn — ConfidentialMintBurn_RotateSupplyElGamalPubkey and _UpdateDecryptableSupply have carried each other's values since the extension was introduced. Either constant produced an instruction that executed on chain as the other one (#504).
  • Token-2022 optional extension addresses — MetadataPointer, TransferHook, GroupPointer, GroupMemberPointer, InterestBearingMint and ScaledUiAmount wrote a one-byte tag and 32 bytes, which is neither COption<Pubkey> nor OptionalNonZeroPubkey (#507).

What's new

Token-2022 confidential extensions

  • Instruction builders for ConfidentialTransferFeeExtension and ConfidentialMintBurnExtension by @matthew-a-klein in #504
  • ConfidentialMintBurn and ConfidentialTransferFee client API by @matthew-a-klein in #511

Fixes

  • Encode optional extension addresses as the program does by @matthew-a-klein in #507
  • Return errors instead of panicking on malformed instruction data by @kriss39 in #501
  • Remove duplicate confidential AccountInfo helpers to break an import cycle by @HealthyBuilder in #500

Staying on v1?

The v1 line continues from main (github.com/gagliardetto/solana-go, latest v1.25.0) and carries both encoding fixes above. v2 differs from v1 only by the module path and the breaking changes listed in the v2.0.0 release notes, plus the VoteAccountsResult.EpochCredits type change from v2.1.0.


Full changelog: v2.1.0...v2.2.0

Don't miss a new solana-go release

NewReleases is sending notifications on new releases.