Complying with Doctrine PSR exceptions