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

[Bug] Error running the example given by jupiter #54

Open
miaobei5555 opened this issue Oct 23, 2024 · 1 comment
Open

[Bug] Error running the example given by jupiter #54

miaobei5555 opened this issue Oct 23, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@miaobei5555
Copy link

Error running the example given by jupiter

`IDexAggregator dex = new JupiterDexAg(account_1.PublicKey);

TokenData tokenA = await dex.GetTokenBySymbol("SOL");
TokenData tokenB = await dex.GetTokenBySymbol("USDC");

SwapQuoteAg swapQuote = await dex.GetSwapQuote(
tokenA.MintAddress,
tokenB.MintAddress,
DecimalUtil.ToUlong(5m, tokenB.Decimals),
SwapMode.ExactOut
);
var quote = DecimalUtil.FromBigInteger(swapQuote.InputAmount, tokenA.Decimals);

Transaction tx = await dex.Swap(swapQuote);

var result = await SignAndSendTransaction(tx, account_1);

Console.WriteLine(result);`

Error Content
Transaction simulation failed: Error processing Instruction 2: Provided seeds do not result in a valid address

Detailed Information
{"jsonrpc":"2.0","error":{"code":-32002,"message":"Transaction simulation failed: Error processing Instruction 2: Provided seeds do not result in a valid address","data":{"accounts":null,"err":{"InstructionError":[2,"InvalidSeeds"]},"innerInstructions":null,"logs":["Program ComputeBudget111111111111111111111111111111 invoke [1]","Program ComputeBudget111111111111111111111111111111 success","Program ComputeBudget111111111111111111111111111111 invoke [1]","Program ComputeBudget111111111111111111111111111111 success","Program ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL invoke [1]","Program log: CreateIdempotent","Program log: Error: Associated address does not match seed derivation","Program ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL consumed 4960 of 1399700 compute units","Program ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL failed: Provided seeds do not result in a valid address"],"returnData":null,"unitsConsumed":5260}},"id":0}

@miaobei5555 miaobei5555 added the bug Something isn't working label Oct 23, 2024
@miaobei5555
Copy link
Author

i am already settling

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant