Custom program error

0xbba3002

Appears in logs as custom program error: 0xbba

Anchor

AccountDiscriminatorMismatch

“Account discriminator did not match what was expected”

The first 8 bytes of the account do not match the expected account type's discriminator.

Common causes

  • Passing the wrong kind of account (for example a Vault where a Config is expected).
  • Passing an account created by an older version of the program with a different struct name.
  • Passing an uninitialised or empty account where a typed account is expected.

How to fix it

  • Check that the address belongs to an account of the right type. If the struct was renamed, migrate or recreate the account.

Decode another error

Try: