Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DI] Maximum function nesting level of '9999' reached #29246

Closed
ro0NL opened this issue Nov 17, 2018 · 2 comments
Closed

[DI] Maximum function nesting level of '9999' reached #29246

ro0NL opened this issue Nov 17, 2018 · 2 comments

Comments

@ro0NL
Copy link
Contributor

ro0NL commented Nov 17, 2018

Symfony version(s) affected: 4.2

Description
After #29078 there seems to be another regression now.

In getDoctrine_Orm_DefaultEntityManagerService.php line 9:
                                                              
  [Symfony\Component\Debug\Exception\FatalThrowableError
  Maximum function nesting level of '9999' reached, aborting!

How to reproduce
See https://github.com/ro0NL/sf

Run php -dxdebug.max_nesting_level=9999 bin/console c:c -vvv

@nicolas-grekas
Copy link
Member

See #29247 - no easy fix.
TL;DR, requiring symfony/proxy-manager-bridge works around the issue properly.

@xabbuh
Copy link
Member

xabbuh commented Nov 19, 2018

#25821 could be related too

nicolas-grekas added a commit that referenced this issue Nov 20, 2018
…e container (nicolas-grekas)

This PR was merged into the 3.4 branch.

Discussion
----------

[DI] fix taking lazy services into account when dumping the container

| Q             | A
| ------------- | ---
| Branch?       | 3.4
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #29246
| License       | MIT
| Doc PR        | -

This PR fixes issues found while working on #29246.
It *does* fix the infinite loop, ~but replaces it by an exception (reopening #29078)~:
> ~It's a requirement to specify a Metadata Driver and pass it to Doctrine\ORM\Configuration::setMetadataDriverImpl()~

The full fix is not immediately accessible as it needs some core changes to the dumping logic. Requiring `symfony/proxy-manager-bridge` works around the issue properly.

See #29251 for 4.2

Commits
-------

67d7623 [DI] fix taking lazy services into account when dumping the container
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants