diff --git a/examples/program_deployment/methods/guest/src/bin/hello_world.rs b/examples/program_deployment/methods/guest/src/bin/hello_world.rs index ea2edd95..9392128f 100644 --- a/examples/program_deployment/methods/guest/src/bin/hello_world.rs +++ b/examples/program_deployment/methods/guest/src/bin/hello_world.rs @@ -18,8 +18,7 @@ type Instruction = Vec; fn main() { // Read inputs let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: greeting, }, @@ -51,11 +50,5 @@ fn main() { // with the NSSA program rules. // WARNING: constructing a `ProgramOutput` has no effect on its own. `.write()` must be // called to commit the output. - ProgramOutput::new( - self_program_id, - instruction_data, - vec![pre_state], - vec![post_state], - ) - .write(); + ProgramOutput::new(self_program_id, instruction_data, vec![pre_state], vec![post_state]).write(); } diff --git a/examples/program_deployment/methods/guest/src/bin/hello_world_with_authorization.rs b/examples/program_deployment/methods/guest/src/bin/hello_world_with_authorization.rs index 3f369fa7..0e1237d8 100644 --- a/examples/program_deployment/methods/guest/src/bin/hello_world_with_authorization.rs +++ b/examples/program_deployment/methods/guest/src/bin/hello_world_with_authorization.rs @@ -18,8 +18,7 @@ type Instruction = Vec; fn main() { // Read inputs let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: greeting, }, @@ -58,11 +57,5 @@ fn main() { // with the NSSA program rules. // WARNING: constructing a `ProgramOutput` has no effect on its own. `.write()` must be // called to commit the output. - ProgramOutput::new( - self_program_id, - instruction_data, - vec![pre_state], - vec![post_state], - ) - .write(); + ProgramOutput::new(self_program_id, instruction_data, vec![pre_state], vec![post_state]).write(); } diff --git a/examples/program_deployment/methods/guest/src/bin/hello_world_with_move_function.rs b/examples/program_deployment/methods/guest/src/bin/hello_world_with_move_function.rs index 57a2190c..7a01f10b 100644 --- a/examples/program_deployment/methods/guest/src/bin/hello_world_with_move_function.rs +++ b/examples/program_deployment/methods/guest/src/bin/hello_world_with_move_function.rs @@ -65,8 +65,7 @@ fn move_data(from_pre: AccountWithMetadata, to_pre: AccountWithMetadata) -> Vec< fn main() { // Read input accounts. let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: (function_id, data), }, diff --git a/examples/program_deployment/methods/guest/src/bin/simple_tail_call.rs b/examples/program_deployment/methods/guest/src/bin/simple_tail_call.rs index 22098b7a..09acfae2 100644 --- a/examples/program_deployment/methods/guest/src/bin/simple_tail_call.rs +++ b/examples/program_deployment/methods/guest/src/bin/simple_tail_call.rs @@ -26,8 +26,7 @@ fn hello_world_program_id() -> ProgramId { fn main() { // Read inputs let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: (), }, @@ -56,12 +55,7 @@ fn main() { // Write the outputs. // WARNING: constructing a `ProgramOutput` has no effect on its own. `.write()` must be // called to commit the output. - ProgramOutput::new( - self_program_id, - instruction_data, - vec![pre_state], - vec![post_state], - ) - .with_chained_calls(vec![chained_call]) - .write(); + ProgramOutput::new(self_program_id, instruction_data, vec![pre_state], vec![post_state]) + .with_chained_calls(vec![chained_call]) + .write(); } diff --git a/examples/program_deployment/methods/guest/src/bin/tail_call_with_pda.rs b/examples/program_deployment/methods/guest/src/bin/tail_call_with_pda.rs index 2ae65ec7..f5d62bc6 100644 --- a/examples/program_deployment/methods/guest/src/bin/tail_call_with_pda.rs +++ b/examples/program_deployment/methods/guest/src/bin/tail_call_with_pda.rs @@ -32,8 +32,7 @@ fn hello_world_program_id() -> ProgramId { fn main() { // Read inputs let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: (), }, @@ -69,12 +68,7 @@ fn main() { // Write the outputs. // WARNING: constructing a `ProgramOutput` has no effect on its own. `.write()` must be // called to commit the output. - ProgramOutput::new( - self_program_id, - instruction_data, - vec![pre_state], - vec![post_state], - ) - .with_chained_calls(vec![chained_call]) - .write(); + ProgramOutput::new(self_program_id, instruction_data, vec![pre_state], vec![post_state]) + .with_chained_calls(vec![chained_call]) + .write(); } diff --git a/nssa/core/src/program.rs b/nssa/core/src/program.rs index 057c8238..3d98aed2 100644 --- a/nssa/core/src/program.rs +++ b/nssa/core/src/program.rs @@ -17,6 +17,7 @@ pub type ProgramId = [u32; 8]; pub type InstructionData = Vec; pub struct ProgramInput { pub self_program_id: ProgramId, + pub caller_program_id: Option, pub pre_states: Vec, pub instruction: T, } @@ -421,12 +422,14 @@ pub fn compute_authorized_pdas( #[must_use] pub fn read_nssa_inputs() -> (ProgramInput, InstructionData) { let self_program_id: ProgramId = env::read(); + let caller_program_id: Option = env::read(); let pre_states: Vec = env::read(); let instruction_words: InstructionData = env::read(); let instruction = T::deserialize(&mut Deserializer::new(instruction_words.as_ref())).unwrap(); ( ProgramInput { self_program_id, + caller_program_id, pre_states, instruction, }, diff --git a/nssa/src/privacy_preserving_transaction/circuit.rs b/nssa/src/privacy_preserving_transaction/circuit.rs index 48c59ce7..3ac5d20e 100644 --- a/nssa/src/privacy_preserving_transaction/circuit.rs +++ b/nssa/src/privacy_preserving_transaction/circuit.rs @@ -87,15 +87,16 @@ pub fn execute_and_prove( pda_seeds: vec![], }; - let mut chained_calls = VecDeque::from_iter([(initial_call, initial_program)]); + let mut chained_calls = VecDeque::from_iter([(initial_call, initial_program, None)]); let mut chain_calls_counter = 0; - while let Some((chained_call, program)) = chained_calls.pop_front() { + while let Some((chained_call, program, caller_program_id)) = chained_calls.pop_front() { if chain_calls_counter >= MAX_NUMBER_CHAINED_CALLS { return Err(NssaError::MaxChainedCallsDepthExceeded); } let inner_receipt = execute_and_prove_program( program, + caller_program_id, &chained_call.pre_states, &chained_call.instruction_data, )?; @@ -115,7 +116,7 @@ pub fn execute_and_prove( let next_program = dependencies .get(&new_call.program_id) .ok_or(NssaError::InvalidProgramBehavior)?; - chained_calls.push_front((new_call, next_program)); + chained_calls.push_front((new_call, next_program, Some(chained_call.program_id))); } chain_calls_counter = chain_calls_counter @@ -153,12 +154,13 @@ pub fn execute_and_prove( fn execute_and_prove_program( program: &Program, + caller_program_id: Option, pre_states: &[AccountWithMetadata], instruction_data: &InstructionData, ) -> Result { // Write inputs to the program let mut env_builder = ExecutorEnv::builder(); - Program::write_inputs(program.id(), pre_states, instruction_data, &mut env_builder)?; + Program::write_inputs(program.id(), caller_program_id, pre_states, instruction_data, &mut env_builder)?; let env = env_builder.build().unwrap(); // Prove the program diff --git a/nssa/src/program.rs b/nssa/src/program.rs index 5ff19fbc..846eb132 100644 --- a/nssa/src/program.rs +++ b/nssa/src/program.rs @@ -52,13 +52,14 @@ impl Program { pub(crate) fn execute( &self, + caller_program_id: Option, pre_states: &[AccountWithMetadata], instruction_data: &InstructionData, ) -> Result { // Write inputs to the program let mut env_builder = ExecutorEnv::builder(); env_builder.session_limit(Some(MAX_NUM_CYCLES_PUBLIC_EXECUTION)); - Self::write_inputs(self.id, pre_states, instruction_data, &mut env_builder)?; + Self::write_inputs(self.id, caller_program_id, pre_states, instruction_data, &mut env_builder)?; let env = env_builder.build().unwrap(); // Execute the program (without proving) @@ -79,6 +80,7 @@ impl Program { /// Writes inputs to `env_builder` in the order expected by the programs. pub(crate) fn write_inputs( program_id: ProgramId, + caller_program_id: Option, pre_states: &[AccountWithMetadata], instruction_data: &[u32], env_builder: &mut ExecutorEnvBuilder, @@ -86,6 +88,9 @@ impl Program { env_builder .write(&program_id) .map_err(|e| NssaError::ProgramWriteInputFailed(e.to_string()))?; + env_builder + .write(&caller_program_id) + .map_err(|e| NssaError::ProgramWriteInputFailed(e.to_string()))?; let pre_states = pre_states.to_vec(); env_builder .write(&pre_states) diff --git a/nssa/src/public_transaction/transaction.rs b/nssa/src/public_transaction/transaction.rs index 8c46c88f..ad33b2cd 100644 --- a/nssa/src/public_transaction/transaction.rs +++ b/nssa/src/public_transaction/transaction.rs @@ -148,7 +148,7 @@ impl PublicTransaction { chained_call.program_id, chained_call.pre_states, chained_call.instruction_data ); let mut program_output = - program.execute(&chained_call.pre_states, &chained_call.instruction_data)?; + program.execute(caller_program_id, &chained_call.pre_states, &chained_call.instruction_data)?; debug!( "Program {:?} output: {:?}", chained_call.program_id, program_output diff --git a/program_methods/guest/src/bin/amm.rs b/program_methods/guest/src/bin/amm.rs index 59c89742..292efb67 100644 --- a/program_methods/guest/src/bin/amm.rs +++ b/program_methods/guest/src/bin/amm.rs @@ -13,8 +13,7 @@ use nssa_core::program::{ProgramInput, ProgramOutput, read_nssa_inputs}; fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction, }, @@ -153,12 +152,7 @@ fn main() { } }; - ProgramOutput::new( - self_program_id, - instruction_words, - pre_states_clone, - post_states, - ) - .with_chained_calls(chained_calls) - .write(); + ProgramOutput::new(self_program_id, instruction_words, pre_states_clone, post_states) + .with_chained_calls(chained_calls) + .write(); } diff --git a/program_methods/guest/src/bin/associated_token_account.rs b/program_methods/guest/src/bin/associated_token_account.rs index 42162ba2..6b22107a 100644 --- a/program_methods/guest/src/bin/associated_token_account.rs +++ b/program_methods/guest/src/bin/associated_token_account.rs @@ -3,8 +3,7 @@ use nssa_core::program::{ProgramInput, ProgramOutput, read_nssa_inputs}; fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction, }, @@ -57,12 +56,7 @@ fn main() { } }; - ProgramOutput::new( - self_program_id, - instruction_words, - pre_states_clone, - post_states, - ) - .with_chained_calls(chained_calls) - .write(); + ProgramOutput::new(self_program_id, instruction_words, pre_states_clone, post_states) + .with_chained_calls(chained_calls) + .write(); } diff --git a/program_methods/guest/src/bin/authenticated_transfer.rs b/program_methods/guest/src/bin/authenticated_transfer.rs index d7c68e62..6a3cdd51 100644 --- a/program_methods/guest/src/bin/authenticated_transfer.rs +++ b/program_methods/guest/src/bin/authenticated_transfer.rs @@ -66,8 +66,7 @@ fn transfer( fn main() { // Read input accounts. let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: balance_to_move, }, diff --git a/program_methods/guest/src/bin/pinata.rs b/program_methods/guest/src/bin/pinata.rs index d6f35ae8..3cbfe1cb 100644 --- a/program_methods/guest/src/bin/pinata.rs +++ b/program_methods/guest/src/bin/pinata.rs @@ -45,8 +45,7 @@ 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, caller_program_id: _, pre_states, instruction: solution, }, diff --git a/program_methods/guest/src/bin/pinata_token.rs b/program_methods/guest/src/bin/pinata_token.rs index 5c31af45..2b90735c 100644 --- a/program_methods/guest/src/bin/pinata_token.rs +++ b/program_methods/guest/src/bin/pinata_token.rs @@ -51,8 +51,7 @@ 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, caller_program_id: _, pre_states, instruction: solution, }, diff --git a/program_methods/guest/src/bin/token.rs b/program_methods/guest/src/bin/token.rs index 2414a289..c62088a4 100644 --- a/program_methods/guest/src/bin/token.rs +++ b/program_methods/guest/src/bin/token.rs @@ -11,8 +11,7 @@ use token_program::core::Instruction; fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction, }, @@ -82,11 +81,5 @@ fn main() { } }; - ProgramOutput::new( - self_program_id, - instruction_words, - pre_states_clone, - post_states, - ) - .write(); + ProgramOutput::new(self_program_id, instruction_words, pre_states_clone, post_states).write(); } diff --git a/test_program_methods/guest/src/bin/burner.rs b/test_program_methods/guest/src/bin/burner.rs index 06ac9b6b..5c58859a 100644 --- a/test_program_methods/guest/src/bin/burner.rs +++ b/test_program_methods/guest/src/bin/burner.rs @@ -4,8 +4,7 @@ type Instruction = u128; fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: balance_to_burn, }, diff --git a/test_program_methods/guest/src/bin/chain_caller.rs b/test_program_methods/guest/src/bin/chain_caller.rs index e8bf9d6f..3c49ef69 100644 --- a/test_program_methods/guest/src/bin/chain_caller.rs +++ b/test_program_methods/guest/src/bin/chain_caller.rs @@ -12,8 +12,7 @@ type Instruction = (u128, ProgramId, u32, Option); /// program. fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: (balance, auth_transfer_id, num_chain_calls, pda_seed), }, diff --git a/test_program_methods/guest/src/bin/changer_claimer.rs b/test_program_methods/guest/src/bin/changer_claimer.rs index c1bd886c..6e10b36b 100644 --- a/test_program_methods/guest/src/bin/changer_claimer.rs +++ b/test_program_methods/guest/src/bin/changer_claimer.rs @@ -5,8 +5,7 @@ type Instruction = (Option>, bool); /// A program that optionally modifies the account data and optionally claims it. fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: (data_opt, should_claim), }, @@ -34,11 +33,5 @@ fn main() { AccountPostState::new(account_post) }; - ProgramOutput::new( - self_program_id, - instruction_words, - vec![pre], - vec![post_state], - ) - .write(); + ProgramOutput::new(self_program_id, instruction_words, vec![pre], vec![post_state]).write(); } diff --git a/test_program_methods/guest/src/bin/claimer.rs b/test_program_methods/guest/src/bin/claimer.rs index 27b1ae73..b0e0602f 100644 --- a/test_program_methods/guest/src/bin/claimer.rs +++ b/test_program_methods/guest/src/bin/claimer.rs @@ -4,8 +4,7 @@ type Instruction = (); fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: (), }, @@ -18,11 +17,5 @@ fn main() { let account_post = AccountPostState::new_claimed(pre.account.clone(), Claim::Authorized); - ProgramOutput::new( - self_program_id, - instruction_words, - vec![pre], - vec![account_post], - ) - .write(); + ProgramOutput::new(self_program_id, instruction_words, vec![pre], vec![account_post]).write(); } diff --git a/test_program_methods/guest/src/bin/data_changer.rs b/test_program_methods/guest/src/bin/data_changer.rs index ee7cb235..4ff214be 100644 --- a/test_program_methods/guest/src/bin/data_changer.rs +++ b/test_program_methods/guest/src/bin/data_changer.rs @@ -5,8 +5,7 @@ type Instruction = Vec; /// A program that modifies the account data by setting bytes sent in instruction. fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: data, }, diff --git a/test_program_methods/guest/src/bin/extra_output.rs b/test_program_methods/guest/src/bin/extra_output.rs index 924f4d8f..86ddb85d 100644 --- a/test_program_methods/guest/src/bin/extra_output.rs +++ b/test_program_methods/guest/src/bin/extra_output.rs @@ -6,14 +6,7 @@ use nssa_core::{ type Instruction = (); fn main() { - let ( - ProgramInput { - self_program_id, - pre_states, - .. - }, - instruction_words, - ) = read_nssa_inputs::(); + let (ProgramInput { self_program_id, caller_program_id: _, pre_states, .. }, instruction_words) = read_nssa_inputs::(); let Ok([pre]) = <[_; 1]>::try_from(pre_states) else { return; diff --git a/test_program_methods/guest/src/bin/malicious_authorization_changer.rs b/test_program_methods/guest/src/bin/malicious_authorization_changer.rs index 1db09a73..ca80043a 100644 --- a/test_program_methods/guest/src/bin/malicious_authorization_changer.rs +++ b/test_program_methods/guest/src/bin/malicious_authorization_changer.rs @@ -13,8 +13,7 @@ type Instruction = (u128, ProgramId); /// but sets the `is_authorized` field of the first account to true. fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: (balance, transfer_program_id), }, diff --git a/test_program_methods/guest/src/bin/minter.rs b/test_program_methods/guest/src/bin/minter.rs index 445df32f..81960fd2 100644 --- a/test_program_methods/guest/src/bin/minter.rs +++ b/test_program_methods/guest/src/bin/minter.rs @@ -3,14 +3,7 @@ use nssa_core::program::{AccountPostState, ProgramInput, ProgramOutput, read_nss type Instruction = (); fn main() { - let ( - ProgramInput { - self_program_id, - pre_states, - .. - }, - instruction_words, - ) = read_nssa_inputs::(); + let (ProgramInput { self_program_id, caller_program_id: _, pre_states, .. }, instruction_words) = read_nssa_inputs::(); let Ok([pre]) = <[_; 1]>::try_from(pre_states) else { return; diff --git a/test_program_methods/guest/src/bin/missing_output.rs b/test_program_methods/guest/src/bin/missing_output.rs index 6b33d95e..e5a38eb7 100644 --- a/test_program_methods/guest/src/bin/missing_output.rs +++ b/test_program_methods/guest/src/bin/missing_output.rs @@ -3,14 +3,7 @@ use nssa_core::program::{AccountPostState, ProgramInput, ProgramOutput, read_nss type Instruction = (); fn main() { - let ( - ProgramInput { - self_program_id, - pre_states, - .. - }, - instruction_words, - ) = read_nssa_inputs::(); + let (ProgramInput { self_program_id, caller_program_id: _, pre_states, .. }, instruction_words) = read_nssa_inputs::(); let Ok([pre1, pre2]) = <[_; 2]>::try_from(pre_states) else { return; diff --git a/test_program_methods/guest/src/bin/modified_transfer.rs b/test_program_methods/guest/src/bin/modified_transfer.rs index 859f5cc0..7344d125 100644 --- a/test_program_methods/guest/src/bin/modified_transfer.rs +++ b/test_program_methods/guest/src/bin/modified_transfer.rs @@ -63,8 +63,7 @@ fn transfer( fn main() { // Read input accounts. let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: balance_to_move, }, diff --git a/test_program_methods/guest/src/bin/nonce_changer.rs b/test_program_methods/guest/src/bin/nonce_changer.rs index 5e1cdbb2..634b653e 100644 --- a/test_program_methods/guest/src/bin/nonce_changer.rs +++ b/test_program_methods/guest/src/bin/nonce_changer.rs @@ -3,14 +3,7 @@ use nssa_core::program::{AccountPostState, ProgramInput, ProgramOutput, read_nss type Instruction = (); fn main() { - let ( - ProgramInput { - self_program_id, - pre_states, - .. - }, - instruction_words, - ) = read_nssa_inputs::(); + let (ProgramInput { self_program_id, caller_program_id: _, pre_states, .. }, instruction_words) = read_nssa_inputs::(); let Ok([pre]) = <[_; 1]>::try_from(pre_states) else { return; diff --git a/test_program_methods/guest/src/bin/noop.rs b/test_program_methods/guest/src/bin/noop.rs index 71787776..0179543d 100644 --- a/test_program_methods/guest/src/bin/noop.rs +++ b/test_program_methods/guest/src/bin/noop.rs @@ -3,14 +3,7 @@ use nssa_core::program::{AccountPostState, ProgramInput, ProgramOutput, read_nss type Instruction = (); fn main() { - let ( - ProgramInput { - self_program_id, - pre_states, - .. - }, - instruction_words, - ) = read_nssa_inputs::(); + let (ProgramInput { self_program_id, caller_program_id: _, pre_states, .. }, instruction_words) = read_nssa_inputs::(); let post_states = pre_states .iter() diff --git a/test_program_methods/guest/src/bin/program_owner_changer.rs b/test_program_methods/guest/src/bin/program_owner_changer.rs index f1b2cfce..7353a8f1 100644 --- a/test_program_methods/guest/src/bin/program_owner_changer.rs +++ b/test_program_methods/guest/src/bin/program_owner_changer.rs @@ -3,14 +3,7 @@ use nssa_core::program::{AccountPostState, ProgramInput, ProgramOutput, read_nss type Instruction = (); fn main() { - let ( - ProgramInput { - self_program_id, - pre_states, - .. - }, - instruction_words, - ) = read_nssa_inputs::(); + let (ProgramInput { self_program_id, caller_program_id: _, pre_states, .. }, instruction_words) = read_nssa_inputs::(); let Ok([pre]) = <[_; 1]>::try_from(pre_states) else { return; diff --git a/test_program_methods/guest/src/bin/simple_balance_transfer.rs b/test_program_methods/guest/src/bin/simple_balance_transfer.rs index 4edd6198..98feb53b 100644 --- a/test_program_methods/guest/src/bin/simple_balance_transfer.rs +++ b/test_program_methods/guest/src/bin/simple_balance_transfer.rs @@ -4,8 +4,7 @@ type Instruction = u128; fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: balance, }, diff --git a/test_program_methods/guest/src/bin/validity_window.rs b/test_program_methods/guest/src/bin/validity_window.rs index 67908836..746eb041 100644 --- a/test_program_methods/guest/src/bin/validity_window.rs +++ b/test_program_methods/guest/src/bin/validity_window.rs @@ -7,8 +7,7 @@ type Instruction = (BlockValidityWindow, TimestampValidityWindow); fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: (block_validity_window, timestamp_validity_window), }, diff --git a/test_program_methods/guest/src/bin/validity_window_chain_caller.rs b/test_program_methods/guest/src/bin/validity_window_chain_caller.rs index cbe3c7c1..dc04a071 100644 --- a/test_program_methods/guest/src/bin/validity_window_chain_caller.rs +++ b/test_program_methods/guest/src/bin/validity_window_chain_caller.rs @@ -15,8 +15,7 @@ type Instruction = (BlockValidityWindow, ProgramId, BlockValidityWindow); fn main() { let ( - ProgramInput { - self_program_id, + ProgramInput { self_program_id, caller_program_id: _, pre_states, instruction: (block_validity_window, chained_program_id, chained_block_validity_window), },