You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While trying to create a simple program that sends buy and sell transactions with the V2 library I get to the stage where I want to simulate the transaction to calculate the compute limit requirements, but it throws an error InvalidSeed. I minimally reproduced the code using the V1 library and it seems to work fine with the same parameters.
Steps to reproduce
This is the V2 Version of the code which is not working
Is it at all possible that you're using the getCreateAssociatedTokenIdempotentInstruction() function from @solana-program/token-2022 that defaults the token program address (when not supplied) to the token-2022 program, which is incompatible with the ATA you're generating with TokenkegQfe... explicitly overridden?
Wow! That was it! Thanks so much! Its unfortunate that that isn't very clear in the API/docs of the instruction itself. I pretty much had given up here.
Overview
While trying to create a simple program that sends buy and sell transactions with the V2 library I get to the stage where I want to simulate the transaction to calculate the compute limit requirements, but it throws an error InvalidSeed. I minimally reproduced the code using the V1 library and it seems to work fine with the same parameters.
Steps to reproduce
This is the V2 Version of the code which is not working
And this is the working V1 version
Description of bug
In both cases, the calculated AssociatedTokenAddress is
7PKtoocp9KBkcaRXPr6j5oib6KMFmjVhfGq1H4Sm33tm
, but in the case of V2 the error isI believe this is a bug. However I would be happy to be proven wrong and told Im doing it wrong. Appreciate any help figuring this out. Thank you!
The text was updated successfully, but these errors were encountered: