-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
move starknet settlement to zaun #125
Conversation
byteZorvin
commented
Sep 18, 2024
- Orchestrator now uses zaun types now to interact with starknet core contract.
.env.example
Outdated
|
||
|
||
##### STARKNET SETTLEMENT TEST ##### |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
##### STARKNET SETTLEMENT TEST ##### | |
##### STARKNET SETTLEMENT (L3s) ##### |
.github/workflows/coverage.yml
Outdated
repository: madara-alliance/madara # Replace with your first repository | ||
ref: "0c821aecd1cafc516d00548473fcaddaa4dc0ce4" # Replace with your branch name |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
repository: madara-alliance/madara # Replace with your first repository | |
ref: "0c821aecd1cafc516d00548473fcaddaa4dc0ce4" # Replace with your branch name | |
repository: madara-alliance/madara | |
ref: "0c821aecd1cafc516d00548473fcaddaa4dc0ce4" |
@@ -197,11 +206,26 @@ impl SettlementClient for StarknetSettlementClient { | |||
if block_number.is_empty() { | |||
return Err(eyre!("Could not fetch last block number from core contract.")); | |||
} | |||
Ok(block_number[0].try_into()?) | |||
|
|||
Ok(u64::from_le_bytes(block_number[0].to_bytes_le()[0..8].try_into().unwrap())) | |||
} | |||
|
|||
/// Returns the nonce for the wallet in use. | |||
async fn get_nonce(&self) -> Result<u64> { | |||
todo!("Yet to impl nonce call for Starknet.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i would ideally add a small test case for this :)
node | ||
} | ||
|
||
async fn wait_for_tx_success( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pending?
use utils::settings::Settings; | ||
|
||
pub async fn spin_up_madara() -> MadaraCmd { | ||
println!("Spinning up madara"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there are some println! pending, can you check
* update dependencies * update imports * updated changelog * added testcase for bytes conversion * fix clippy error * use zaun for starknet * add simple test for settlement * add sepolia issue * to be fixed: validation error * add madara update state test * use relative path * add ci for settlement client * fix workflow debug * fix workflow debug * add scarb build * ignore flaky test * fix threads issue * add scarb build for madara * check if tool version present * fix workflow debug * fix workflwo * fix directory * should fix it * fix bash command * fix bash command * make scarb installation separate step * use swm action * fix ci path * lint fixed * fix env path for tests * fix lint * remove extra path * try checking structure * check * fix env path * fix the directory * try go into * fix path * remove working directory * final fix * fix: gets triggered multiple times * fix path * fix prettier * change calldata type to (#133) * update workflow * fix lints * Update crates/settlement-clients/starknet/src/tests/test.rs Co-authored-by: Apoorv Sadana <95699312+apoorvsadana@users.noreply.github.com> * resolve comments * fix e2e test flow * fix toml lint * Update crates/settlement-clients/starknet/src/tests/test.rs Co-authored-by: Apoorv Sadana <95699312+apoorvsadana@users.noreply.github.com> * changed envs * add conversion function and test * remove redundant test * update workflow commit hash * change commit and add prettierignore * nonce implementaion and optimise code * remove coverage bin env * changed to logs * added preset file * update versioned constants path * fix current_path * should do inplace replacement * fix base path * fix final coverage workflow * update preset * change runner * install dependencies * run linter * remove path * reword * change default rust * rerun * install libclang * install more dependencies * install yq * install via snap * install snap first * add y flag * no y flag * enable snapd service * use gh action for yq * yq action * remove working-directory * check env variable * fix ci * remove override in e2e * dotenvy::from_filename * should also build * env override * ignore flaky test * restart ci * enable cargo build * override in starknet client * only starknet * retry running * test settle should work * remove fail fast * update blocktime * change commit * run all tests * resolve comments * added test for get nonce * remove log --------- Co-authored-by: Apoorv Sadana <95699312+apoorvsadana@users.noreply.github.com>