Accept the wallet's Lighthouse guard instructions on sponsored placement - #4960
Conversation
|
Claude finished @squadgazzz's task in 2m 57s —— View job Review
The change is sound and the reasoning in the description holds up: pulling Lighthouse instructions out of the bundle (like compute-budget) before One non-blocking point left inline: Nit (not worth a change): empty-data Lighthouse instructions fall into the I couldn't run |
…w-lighthouse-guards # Conflicts: # crates/solana-orderbook/src/infra/api/routes/create_order/mod.rs
Description
#4958 let the wallet's compute-budget instructions through, which unblocked MetaMask. Phantom also wraps the bundle in Lighthouse guard instructions, so it still fails, and in the same two places: an assertion after
CreateOrdermissessplit_last, and the assertions in front land in the preparations where the template rejects the program.Decoding the transaction Denis reported, all four are assertions,
AssertAccountInfoMultithree times andAssertTokenAccountMultionce. One of them covers the funder, so Phantom is guarding the fee payer rather than spending it. Assertions read account state and abort the transaction on a mismatch, so they cannot move funds and can sit outside the template like the compute budget.MemoryWriteandMemoryClosestay rejected. Both name a payer that funds the memory account's rent, and on a sponsored creation that payer can be the funder.Changes
How to test
Updated integration tests. The end-to-end placement test now sends Phantom's shape, guards before and after, and fails without this change.