I am deploying a Symfony2 application but getting the following error:
FatalErrorException in classes.php line 0:
Error: Method Symfony\Component\HttpFoundation\Request::__toString() must not throw an exception
Apache is a little more descriptive, stating something about Monologue:
PHP Fatal error: Method Symfony\\Component\\HttpFoundation\\Request::__toString() must not throw an exception in /my/path/vendor/monolog/monolog/src/Monolog/Formatter/NormalizerFormatter.php on line 0
This is also the only thing that I don’t understand how this happens. The dev environment on my local machine is working fine.
I tried to clear the prod cache, composer's cache and restart the apache service. I also did a new “composer setup” after clearing the cache.
Does anyone have an idea how this can be solved? Launched Symfony v2.7.4.
source
share