mario-eth / soldeer

Solidity Package Manager written in rust
MIT License
188 stars 19 forks source link

Audit all `unwrap`, `expect`, and other panicking calls #156

Open DaniPopes opened 2 weeks ago

DaniPopes commented 2 weeks ago

An application should never panic due to user error, and instead return/bubble up an error which can also be discarded if need be.

Currently a lot of functions will panic if IO operation goes wrong (utils::read_file_to_string, utils::check_dotfiles), an file or environment variable is malformed (auth::get_token)...

These should ideally just use the common error type and use ? to convert all IO errors etc to it, and bubble them up.

beeb commented 2 days ago

A lot of these (if not all) are fixed in the 0.4.0 milestone branch!