-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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-js: Add sync version of getAssociatedTokenAddress #3050
Comments
You've stumbled on the exact issue -- since this relies on |
Now that web3.js has a sync version of |
How often does the web3.js dependency get updated? I'd be happy to implement this but I don't want to sneak in an unwelcome dependency change, and it looks like we need at least web3.js version 1.40 (currently on 1.36) for this change (solana-labs/solana-web3.js@v1.39.1...v1.40.0). |
It's done as needed, so feel free to do the bump if needed! |
solana-program-library/token/js/src/state/mint.ts
Line 114 in 48fbb5b
This references (async) PublicKey.findProgramAddress, which references (async) PublicKey.createProgramAddress...but I'm not sure why https://github.com/solana-labs/solana-web3.js/blob/d93efdf/src/publickey.ts#L146 needs to be async. I may be missing something! It would just be nice to be able to neatly call this synchronously in a test or whatnot without bubbling up async/await.
The text was updated successfully, but these errors were encountered: