4

i'm stucked at something i've done many many times, and i don't get the problem. I want to init a PDA, i use the following code :

#[account( init, payer = owner, seeds = [METADATA_ACCOUNT_PREFIX.as_bytes(), mint.key().as_ref()], token::mint = mint, token::authority = owner, bump, )] pub real_metadata_account: Box<Account<'info, TokenAccount>>,

if i comment it, everything works as expected, but as soon as i uncomment it i get the following error:

Program failed to complete: Instruction passed to inner instruction is too large (12884933556 > 1280)

Like if the program fails to init the account in the inner instruction, but i don't get why there would be that much data.

I used many times init with similar seeds, and never had any problem. for information, i tried with different mint addresses.

metadata_account_prefix is just a string of letters.

any idea ?

1
  • This doesn't work for me, when i downgrade the solana version then i won't able to build my program through anchor build cmd. Do i need to downgrade my anchor version as well? Aug 2, 2023 at 8:34

1 Answer 1

3

Was stuck on this forever too.

Found this issue directly on Github and followed: https://github.com/coral-xyz/anchor/issues/2520

I advise to eliminate the current version of solana on your pc since 1.16.0 seems to creating problems.

Find the origin of the Solana Folder by using

which Solana

Eliminate the folder by navigating upstream till probably the .local folder and doing

rm -R solana

Then install the version 1.14.18

sh -c "$(curl -sSfL https://release.solana.com/v1.14.18/install)"

Let me know if that solves it!

1
  • You could actually have different versions of solana on your system using solana-install. switch to a different solana version using solana-install init 1.14.18 No need to find and remove the solana folder.
    – Jimii
    Sep 13, 2023 at 7:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.