Skip to content

Commit

Permalink
Merge pull request #2168 from AleoHQ/feat/log-error
Browse files Browse the repository at this point in the history
Update log error handling
  • Loading branch information
howardwu authored Nov 9, 2023
2 parents 7368adf + b833f75 commit bac9e17
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
5 changes: 3 additions & 2 deletions ledger/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,9 @@ impl<N: Network, C: ConsensusStorage<N>> Ledger<N, C> {
let timer = timer!("Ledger::load_unchecked");

// Initialize the consensus store.
let Ok(store) = ConsensusStore::<N, C>::open(dev) else {
bail!("Failed to load ledger (run 'snarkos clean' and try again)");
let store = match ConsensusStore::<N, C>::open(dev) {
Ok(store) => store,
Err(e) => bail!("Failed to load ledger (run 'snarkos clean' and try again)\n\n{e}\n"),
};
lap!(timer, "Load consensus store");

Expand Down
1 change: 1 addition & 0 deletions synthesizer/process/src/stack/register_types/initialize.rs
Original file line number Diff line number Diff line change
Expand Up @@ -305,6 +305,7 @@ impl<N: Network> RegisterTypes<N> {
operand: &Operand<N>,
register_type: &RegisterType<N>,
) -> Result<()> {
#[cfg(feature = "aleo-cli")]
match operand {
// Inform the user the output operand is an input register, to ensure this is intended behavior.
Operand::Register(register) if self.is_input(register) => {
Expand Down

0 comments on commit bac9e17

Please sign in to comment.