Error: InvalidSplTokenProgram for Raydium basic swaps
Unable to land raydium swaps with the cli. The error, when tried to force land txn with bloXroute, as seen on solscan comes out to be:
#3 Raydium Liquidity Pool V4 instruction
> Program log: Error: InvalidSplTokenProgram
> Program
image
[Raydium Liquidity Pool V4](https://solscan.io/account/675kPX9MHTjS2zt1qfr1NYHuzeLXfQM9H24wFSUt1Mp8) consumed 10088 of 61012 compute units
> Program returned error: custom program error: 0x26
Txn https://solscan.io/tx/37SHUfxWtp6LXnyG7LtGtXi3m1Y1Ak1YxWGmnb9PraTDyYNyHMe6Se7XsPnhmaVMwYBZpCTe2iCqtJhH4jtGyEfE
please help tested again, thanks, i updated the swapOnlyAmmUsingBloXRoute method
thanks, just tested i feel its not about jito or bloX. its related to raydium txn generation. with jito unable to confirm the txn even with high fee, and blox just lands it as a failure (nature of it).
i noticed in src/raydium/pool/swap.ts you have used raydium-sdk (not the v2), could it be the problem. thanks.
Ah yes, we need to rewrite it as raydium sdk package somehow keeps changing its function, I will find the latest IDL of Raydium program later and try anchor client to generate the swap txn. Thanks
Come to dc channel if u need help thanks !
Yeahh, pls share link. The last one is expired ig. Thanks
https://discord.gg/pVXx52jk
From what i noted is we have to change every @raydium-io/raydium-sdk usage to v2 and the respective functions. Raydium v2 has different functions for formatting pool info eg. ApiPoolInfoV4 and more. @outsmartchad can you help me do it faster since you know the code in and out. I am struggling with solana-trading-cli/src/raydium/Pool/formatAmmKeysById.ts formatting especillay. thanks
PS I referred to raydium-sdk-V2-demo to confirm we have to make changes.