Instruction
AccountDataTooSmall
“account data too small for instruction”
An account's data buffer is smaller than the program requires.
Common causes
- Allocating too little
spacefor an account. - Using an account created by an older program version with a smaller struct.
How to fix it
- Allocate the correct size. Anchor accounts need 8 bytes for the discriminator plus the struct size.