fix: serialize write_inputs fields separately to match guest deserialization

This commit is contained in:
Moudy
2026-04-02 20:29:12 +02:00
parent 9ecf186851
commit 59d3d38448
22 changed files with 41 additions and 17 deletions
+2 -1
View File
@@ -13,7 +13,8 @@ use nssa_core::program::{ProgramInput, ProgramOutput, read_nssa_inputs};
fn main() {
let (
ProgramInput { self_program_id: _,
ProgramInput {
self_program_id: _,
pre_states,
instruction,
},
@@ -3,7 +3,8 @@ use nssa_core::program::{ProgramInput, ProgramOutput, read_nssa_inputs};
fn main() {
let (
ProgramInput { self_program_id: _,
ProgramInput {
self_program_id: _,
pre_states,
instruction,
},
@@ -66,7 +66,8 @@ fn transfer(
fn main() {
// Read input accounts.
let (
ProgramInput { self_program_id: _,
ProgramInput {
self_program_id: _,
pre_states,
instruction: balance_to_move,
},
+2 -1
View File
@@ -45,7 +45,8 @@ fn main() {
// Read input accounts.
// It is expected to receive only two accounts: [pinata_account, winner_account]
let (
ProgramInput { self_program_id: _,
ProgramInput {
self_program_id: _,
pre_states,
instruction: solution,
},
@@ -51,7 +51,8 @@ fn main() {
// It is expected to receive three accounts: [pinata_definition, pinata_token_holding,
// winner_token_holding]
let (
ProgramInput { self_program_id: _,
ProgramInput {
self_program_id: _,
pre_states,
instruction: solution,
},
+2 -1
View File
@@ -11,7 +11,8 @@ use token_program::core::Instruction;
fn main() {
let (
ProgramInput { self_program_id: _,
ProgramInput {
self_program_id: _,
pre_states,
instruction,
},