-
Notifications
You must be signed in to change notification settings - Fork 25
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(blockifier): invoke() declare() deploy_account() change ret val…
… to api_tx
- Loading branch information
1 parent
0502be4
commit 48dec19
Showing
11 changed files
with
120 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
use starknet_api::contract_class::ClassInfo; | ||
use starknet_api::executable_transaction::AccountTransaction as ExecutableTransaction; | ||
use starknet_api::executable_transaction::AccountTransaction; | ||
use starknet_api::test_utils::declare::{executable_declare_tx, DeclareTxArgs}; | ||
|
||
use crate::transaction::account_transaction::AccountTransaction; | ||
|
||
// TODO(AvivG): remove this func & file. | ||
pub fn declare_tx(declare_tx_args: DeclareTxArgs, class_info: ClassInfo) -> AccountTransaction { | ||
// TODO(AvivG): see into making 'executable_declare_tx' ret type AccountTransaction. | ||
let declare_tx = executable_declare_tx(declare_tx_args, class_info); | ||
|
||
AccountTransaction { tx: ExecutableTransaction::Declare(declare_tx), only_query: false } | ||
AccountTransaction::Declare(declare_tx) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,14 @@ | ||
use starknet_api::executable_transaction::AccountTransaction as ExecutableTransaction; | ||
use starknet_api::executable_transaction::AccountTransaction; | ||
use starknet_api::test_utils::deploy_account::{executable_deploy_account_tx, DeployAccountTxArgs}; | ||
use starknet_api::test_utils::NonceManager; | ||
|
||
use crate::transaction::account_transaction::AccountTransaction; | ||
|
||
// TODO(AvivG): remove this func & file. | ||
pub fn deploy_account_tx( | ||
deploy_tx_args: DeployAccountTxArgs, | ||
nonce_manager: &mut NonceManager, | ||
) -> AccountTransaction { | ||
// TODO(AvivG): see into making 'executable_deploy_account_tx' ret type AccountTransaction. | ||
let deploy_account_tx = executable_deploy_account_tx(deploy_tx_args, nonce_manager); | ||
|
||
AccountTransaction { | ||
tx: ExecutableTransaction::DeployAccount(deploy_account_tx), | ||
only_query: false, | ||
} | ||
AccountTransaction::DeployAccount(deploy_account_tx) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,8 @@ | ||
use starknet_api::executable_transaction::AccountTransaction as ExecutableTransaction; | ||
use starknet_api::executable_transaction::AccountTransaction; | ||
use starknet_api::test_utils::invoke::{executable_invoke_tx, InvokeTxArgs}; | ||
|
||
use crate::transaction::account_transaction::AccountTransaction; | ||
|
||
// TODO(AvivG): remove this func & file. | ||
pub fn invoke_tx(invoke_args: InvokeTxArgs) -> AccountTransaction { | ||
let only_query = invoke_args.only_query; | ||
let invoke_tx = ExecutableTransaction::Invoke(executable_invoke_tx(invoke_args)); | ||
|
||
AccountTransaction { tx: invoke_tx, only_query } | ||
// TODO(AvivG): see into making 'executable_invoke_tx' ret type AccountTransaction. | ||
AccountTransaction::Invoke(executable_invoke_tx(invoke_args)) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.