Skip to content

[DI] Improve service not found in service subscribers #25261

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

Closed
wants to merge 1 commit into from
Closed

[DI] Improve service not found in service subscribers #25261

wants to merge 1 commit into from

Conversation

ro0NL
Copy link
Contributor

@ro0NL ro0NL commented Dec 1, 2017

Q A
Branch? master
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #25196
License MIT
Doc PR symfony/symfony-docs#...

Here you go. Not sure about silently ignoring alternatives though.. but from ServiceLocator this are all available services (not levenshtein tested or so) so this seems more useful.

Perhaps do a levenshtein test here to reduce alternatives and then combine?

@ro0NL
Copy link
Contributor Author

ro0NL commented Dec 2, 2017

ok for 3.4 also? not sure why wait half a year to start helping here. Besides it would ease tests a bit :)

Really not sure about ignoring alternatives. When using a Container (as shown in test) you truly get levenshtein tested alternatives, thus useful also. (This scenario legitimates doing it in ServiceNotFoundException btw, taking a bit of overhead for granted).

So leaning to Did you forget to add it to "..." or did you mean one of these: "..." as full example.

WDYT?

@nicolas-grekas
Copy link
Member

See #25367 for alternative.

@nicolas-grekas
Copy link
Member

Even better alternative: #25381

@nicolas-grekas
Copy link
Member

Closing in favor of #25381
Thanks for the try @ro0NL

@ro0NL ro0NL deleted the servicesubscriber branch December 9, 2017 07:34
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.

3 participants