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

[DependencyInjection] Fix fetching lazy non-shared services multiple times with as files true #50996

Merged

Conversation

HypeMC
Copy link
Contributor

@HypeMC HypeMC commented Jul 16, 2023

Q A
Branch? 6.3
Bug fix? yes
New feature? no
Deprecations? no
Tickets Fix #50975
License MIT
Doc PR -

Followup to #50985, fixes case when as_files is true.

This particular problem exists only on v6.3 and was introduced in #48469.

@carsonbot carsonbot added this to the 6.3 milestone Jul 16, 2023
@HypeMC HypeMC force-pushed the fix-fetching-of-lazy-non-shared-services-2 branch 2 times, most recently from 213940b to a12184c Compare July 16, 2023 22:02
@HypeMC HypeMC force-pushed the fix-fetching-of-lazy-non-shared-services-2 branch from a12184c to cb434a4 Compare July 16, 2023 22:21
Comment on lines -775 to +757
->register('foo', Foo::class)
->register('foo', \Bar\FooLazyClass::class)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A minor mistake I made in my original PR, doesn't really change anything, but it makes the test a bit more consistent.

Comment on lines +814 to +817
$lastDump = array_pop($dumps);
foreach (array_reverse($dumps) as $dump) {
eval('?>'.$dump);
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a better way to do this?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nah, that's fine

@nicolas-grekas
Copy link
Member

Thank you @HypeMC.

@nicolas-grekas nicolas-grekas merged commit 0479bd1 into symfony:6.3 Jul 19, 2023
8 of 9 checks passed
@HypeMC HypeMC deleted the fix-fetching-of-lazy-non-shared-services-2 branch July 19, 2023 19:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants