-
-
Notifications
You must be signed in to change notification settings - Fork 4k
Description
What problem does this solve or what need does it fill?
In bigger Projects there is already a lot going on in the Terminal during runtime. If now forgetting to add some Resource etc. generates only logging (or nothing at all), that something won't happen, but the app otherwise launching and working often entails debugging that wouldn't be necessary in the first place, if it would just crash the program with the log message as the panic message, as it was historically.
If a Resource etc. is missing, it's supposed to interrupt my workflow, which is why i consider the old behavior a safeguard.
What solution would you like?
Some Sort of functionality to toggle the behavior globally. It could be one of these things:
- A Flag to set it to panic, log or none globally by default, with the option to override it, as seen in 0.15 (could be nice, since it could be disabled for release builds. This could be problematic with other parts of bevy potentially).
- An Option in DefaultPlugins (That defines the default behavior for all Systems. Same Problem as first Option)
- An Option to set the Default behavior on a Plugin level (All systems added via this plugin have the following behavior of none, logging once, loggin always, panic)
- Catching nonworking SystemParams (like a missing Resource) in a System without defined behaviour (not using .never_param_warn(), ...) during compile time and throwing a hard error (i'm not sure how possible that would be, if at all)
The Last option would be personally my favourite.
What alternative(s) have you considered?
Not upgrading to 0.15 just yet, until some interface is available to toggle to this or a similarly obvious behavior.
Additional context
i'm talking specifically about the feature mentioned in https://bevyengine.org/news/bevy-0-15/#fallible-system-parameters