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

Integrate basic token-2022 support #311

Merged
merged 3 commits into from
Dec 15, 2023
Merged

Conversation

joncinque
Copy link
Collaborator

Problem

Token-2022 has been around for awhile, but the explorer still has no knowledge of it!

Summary of changes

This is really just basic support, and it was done in a pretty simple manner:

  • look for instances of "spl-token", which is the program name returned from JSON-parsed encoding, and make sure that it also supports "spl-token-2022"
  • look for instances of TOKEN_PROGRAM_ID, and make sure that it also supports TOKEN_2022_PROGRAM_ID

So in the end, accounts and mints are properly displayed, and the additional token-2022 accounts are fetched too.

There is no parsing of extensions included in this PR, but it can certainly be done in follow-up work.

@joncinque joncinque requested a review from mcintyre94 December 13, 2023 00:15
Copy link

vercel bot commented Dec 13, 2023

@joncinque is attempting to deploy a commit to the Solana Labs Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

vercel bot commented Dec 15, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
explorer ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 15, 2023 10:29am

Copy link
Collaborator

@mcintyre94 mcintyre94 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! We need to figure out how to get these token-2022 tokens into search and our token lookup though!

@joncinque joncinque merged commit 91eab21 into solana-labs:master Dec 15, 2023
4 checks passed
@joncinque joncinque deleted the tk22 branch December 15, 2023 11:53
@joncinque
Copy link
Collaborator Author

Yeah for sure! The emphasis for this PR should be on the word "basic" 😅

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