I would like all errors (notices, etc) to be treated as exceptions in Symfony 3.4 and to halt the application.
This is the same for PHP as "use strict" in JavaScript.
Edit:
When using debug true when creating an AppKernel it enables strict mode.
However this is not what I want. This mode is for production, not for debugging and debugging should not be enabled in production so the question is how to enable it without enabling debug.