log_error()
, log_warning()
, log_info()
and log_header()
should use .expect()
instead of .unwrap()
#712
Labels
Currently there are lots of usages of
unwrap()
in production code, in the logging helpers in:https://github.com/heroku/libcnb.rs/blob/2698a713edf19034e382aa702e12acc1516da8fa/libherokubuildpack/src/log.rs
Whilst the nature of these failure modes means that we can't use a Result (and so panicing is appropriate) - we should use
.expect()
instead of an.unwrap()
so at least the panic message is more descriptive.The text was updated successfully, but these errors were encountered: