Skip to content

Commit

Permalink
add correction from PR remarks
Browse files Browse the repository at this point in the history
  • Loading branch information
musitdev committed Jun 21, 2024
1 parent afc7860 commit 63b2e39
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 14 deletions.
19 changes: 8 additions & 11 deletions networks/suzuka/suzuka-full-node/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ fn main() -> Result<ExitCode, anyhow::Error> {
tracing::error!("Suzuka node main task exit with an error : {err}",);
}

// Terminate all runtime task.
// Terminate all running task.
runtime.shutdown_background();
Ok(ExitCode::SUCCESS)
}
Expand Down Expand Up @@ -55,16 +55,13 @@ async fn start_suzuka() -> Result<(), anyhow::Error> {
});

//Start suzuka node process
let (gb_jh, run_jh) = {
let dot_movement = dot_movement::DotMovement::try_from_env()?;
let config = dot_movement.try_get_config_from_json::<suzuka_config::Config>()?;
let (executor, background_task) = SuzukaPartialNode::try_from_config(config)
.await
.context("Failed to create the executor")?;
let gb_jh = tokio::spawn(background_task);
let run_jh = tokio::spawn(async move { executor.run().await });
(gb_jh, run_jh)
};
let dot_movement = dot_movement::DotMovement::try_from_env()?;
let config = dot_movement.try_get_config_from_json::<suzuka_config::Config>()?;
let (executor, background_task) = SuzukaPartialNode::try_from_config(config)
.await
.context("Failed to create the executor")?;
let gb_jh = tokio::spawn(background_task);
let run_jh = tokio::spawn(async move { executor.run().await });

// Wait for a task to end.
select! {
Expand Down
1 change: 0 additions & 1 deletion protocol-units/settlement/mcr/client/src/eth/mod.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
pub mod mcr;
// pub mod staking;
pub mod utils;
4 changes: 2 additions & 2 deletions util/commander/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ async fn pipe_error_output<R: tokio::io::AsyncRead + Unpin + Send + 'static>(
pub async fn run_command(command: &str, args: &[&str]) -> Result<String> {

// print command out with args joined by space
println!("Running command: {} {}", command, args.join(" "));
tracing::info!("Running command: {} {}", command, args.join(" "));

let mut child = Command::new(command)
.args(args)
Expand Down Expand Up @@ -82,7 +82,7 @@ pub async fn run_command(command: &str, args: &[&str]) -> Result<String> {
pub async fn spawn_command(command: String, args: Vec<String>) -> Result<(Option<u32>, JoinHandle<Result<String, anyhow::Error>>)> {

// print command out with args joined by space
println!("spawn command: {} {}", command, args.join(" "));
tracing::info!("spawn command: {} {}", command, args.join(" "));

let mut child = Command::new(&command)
.args(&args)
Expand Down

0 comments on commit 63b2e39

Please sign in to comment.