What problem does this solve or what need does it fill?
Unwrap should generally be avoided. We already encourage contributors to avoid the use of Option::unwrap, yet crashes from panics are still one of the most common categories of issues we're seeing now.
What solution would you like?
- Enable the clippy
unwrap_used lint at a workspace level, and add allow-unwrap-in-tests = true to Clippy.toml.
- Replace actual expected crashes with
expect or unwrap_or_else with a panic where possible, otherwise properly gracefully handle the error.
- Preferably avoid panicking in the renderer entirely, instead failing gracefully where possible by logging a warning and not rendering anything or using blatantly obvious errors (i.e. Valve's missing texture shader).
What alternative(s) have you considered?
Leaving it as is. Keep crashing from unwraps.
Status
What problem does this solve or what need does it fill?
Unwrap should generally be avoided. We already encourage contributors to avoid the use of
Option::unwrap, yet crashes from panics are still one of the most common categories of issues we're seeing now.What solution would you like?
unwrap_usedlint at a workspace level, and addallow-unwrap-in-tests = trueto Clippy.toml.expector unwrap_or_else with a panic where possible, otherwise properly gracefully handle the error.What alternative(s) have you considered?
Leaving it as is. Keep crashing from unwraps.
Status