Instruction
ExternalAccountLamportSpend
“instruction spent from the balance of an account it does not own”
A program tried to debit lamports from an account it does not own.
Common causes
- Writing
**account.lamports.borrow_mut() -= xon an account owned by another program (for example a user's wallet).
How to fix it
- Debit system-owned accounts via a System Program
transferCPI signed by the owner.