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: Display all mint and account extensions #5495

Merged
merged 2 commits into from
Oct 12, 2023

Conversation

joncinque
Copy link
Contributor

@joncinque joncinque commented Oct 11, 2023

Problem

There are many extensions that aren't displayed by the token CLI, because it's using the older parsers.

Solution

The parsers were updated in solana-labs/solana#33453 though, so use all of those!

Before, a devnet mint with metadata showed no extensions, and now it'll show:

SPL Token Mint
  Address: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
  Program: TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb
  Supply: 3000000
  Decimals: 6
  Mint authority: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
  Freeze authority: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Extensions
  Permanent delegate: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
  Metadata Pointer:
    Authority: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    Metadata address: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
  Metadata:
    Update Authority: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    Mint: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    Name: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    Symbol: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    URI: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

While I was at it, I removed the ad-hoc confidential parser.

samkim-crypto
samkim-crypto previously approved these changes Oct 11, 2023
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.

Looks good to me! Thanks!

Comment on lines 706 to 707
writeln_name_value(f, " Pending Balance Low:", pending_balance_lo)?;
writeln_name_value(f, " Pending Balance Hi:", pending_balance_hi)?;
Copy link
Contributor

@samkim-crypto samkim-crypto Oct 11, 2023

Choose a reason for hiding this comment

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

Seems like we should stick to either Lo/Hi or Low/High?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah right, good call, what do you prefer? Maybe we go Low / High for clarity?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yeah, I think Low/High will be nice.

@mergify mergify bot dismissed samkim-crypto’s stale review October 11, 2023 19:15

Pull request has been modified.

@joncinque joncinque merged commit d68329c into solana-labs:master Oct 12, 2023
29 checks passed
@joncinque joncinque deleted the tkclidisp branch October 12, 2023 03:55
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