|
|
|
@ -771,7 +771,7 @@ async fn run(config: Config) -> Result<(), AnyError> {
|
|
|
|
|
Ok(()) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
fn main() { |
|
|
|
|
fn main() -> Result<(), anyhow::Error> { |
|
|
|
|
let begin = Instant::now(); |
|
|
|
|
dotenvy::dotenv().ok(); |
|
|
|
|
|
|
|
|
@ -786,9 +786,13 @@ fn main() {
|
|
|
|
|
.build() |
|
|
|
|
.unwrap(); |
|
|
|
|
|
|
|
|
|
rt.block_on(run(config)).unwrap(); |
|
|
|
|
if let Err(err) = rt.block_on(run(config)) { |
|
|
|
|
error!(?err, "something went wrong!"); |
|
|
|
|
anyhow::bail!("fatal error: {:?}", err); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
info!("finished in {:?}", begin.elapsed()); |
|
|
|
|
Ok(()) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
#[cfg(test)] |
|
|
|
|