Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I have spotted a PHP fatal error in the logs for a project I'm working on:
PHP Fatal error: Nesting level too deep - recursive dependency? in docroot/vendor/twig/twig/lib/Twig/Environment.php(403) : eval()'d code on line 136 request_id="v-8dab77ce-f84f-11e6-a484-22000b0b6021"
The problematic line is:
eval('?>'.$content);
Has anyone else experienced the same issue, or have any idea what could be causing this? I can spend some time digging into this if anyone has some initial pointers.
Comments
Comment #2
cilefen CreditAttribution: cilefen commentedHave you got xdebug enabled?
Comment #3
jamesquinton CreditAttribution: jamesquinton at Mirum Agency commentedGood point!
Comment #4
jamesquinton CreditAttribution: jamesquinton at Mirum Agency commentedI tracked this down to a twig template that was comparing two objects in an if statement - this was causing the fatal error.