Skip to content
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

token-cli: Fix updating metadata with offline signer #5496

Merged
merged 1 commit into from
Oct 13, 2023

Conversation

joncinque
Copy link
Contributor

Problem

Even though #5326 attempted to add offline signing support for update-metadata, it did not cover the case of updating metadata and transferring lamports to cover the new rent-exempt amount of the account.

Solution

Add a new --transfer-lamports parameter which is required for offline signing. With this PR, you can do:

$ spl-token update-metadata 5K8RVdjpY3CHujyKjQ7RkyiCJqTG8Kba9krNfpZnmvpS new-field new-value --sign-only --blockhash 5K8RVdjpY3CHujyKjQ7RkyiCJqTG8Kba9krNfpZnmvpS --transfer-lamports 10

Blockhash: 5K8RVdjpY3CHujyKjQ7RkyiCJqTG8Kba9krNfpZnmvpS
Signers (Pubkey=Signature):
 4SnSuUtJGKvk2GYpBwmEsWG53zTurVM8yXGsoiZQyMJn=3oMKkcJPxceeKByiqawu39LttYkpSUFBC3oLDsjkogBGvCiZ8SLpPFMaSt5pGWfT9fg6H8R8MXXzbRNX2Sx12RBa

Copy link
Contributor

@samkim-crypto samkim-crypto left a comment

Choose a reason for hiding this comment

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

Everything looks clean to me!

@joncinque joncinque merged commit 1d8d883 into solana-labs:master Oct 13, 2023
29 checks passed
@joncinque joncinque deleted the tkclioff branch October 13, 2023 14:45
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.

2 participants