-
Notifications
You must be signed in to change notification settings - Fork 225
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(nargo): report bubbled up errors using eyre (#907)
* chore(nargo): report errors using anyhow * chore: replace anyhow with eyre
- Loading branch information
1 parent
007ab75
commit e87ce66
Showing
3 changed files
with
11 additions
and
23 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
#![forbid(unsafe_code)] | ||
|
||
use color_eyre::config::HookBuilder; | ||
use color_eyre::{config::HookBuilder, eyre}; | ||
use nargo::cli::start_cli; | ||
|
||
fn main() { | ||
fn main() -> eyre::Result<()> { | ||
// Register a panic hook to display more readable panic messages to end-users | ||
let (panic_hook, _) = HookBuilder::default() | ||
.display_env_section(false) | ||
.panic_section("This is a bug. Consider opening an issue at https://github.com/noir-lang/noir/issues/new?labels=bug&template=bug_report.md") | ||
.into_hooks(); | ||
panic_hook.install(); | ||
|
||
start_cli(); | ||
start_cli() | ||
} |