-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[FrameworkBundle] don't register some AssetMapper services without configured HTTP clients #57219
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
Conversation
xabbuh
commented
May 29, 2024
Q | A |
---|---|
Branch? | 6.4 |
Bug fix? | yes |
New feature? | no |
Deprecations? | no |
Issues | see #57073 (comment) |
License | MIT |
I'm not sure if this is the way to do it to be honest. If I understand it correctly, when While with my PR, I did not inject the default http_client but instead, let the service class in question create it's own HttpClient. I think this PR will actually break things for people that have http_client disabled. |
Another solution is to do the following: If the The AssetMapper component already requires HttpClient. But on the Framework level, there is no guarantee that the |
Not sure about that, those service have already been unusable before as you pointed out in your PR. So this doesn't change here. |
That's right, it was already broken indeed. Solving it like this would be the way to go if you ask me: #57219 (comment) Instead of removing the functionality that produced an error, it would solve the functionality, without needing addition work for the user. |
@xabbuh what do you about this ? I can create a PR in this direction if you want (as asset-mapper does require http-client as direct dependency, it would allow to fix things for everyone.... or am i beeing naive here ?) |
…se asset-mapper while http-client is disabled (nicolas-grekas) This PR was merged into the 6.4 branch. Discussion ---------- [FrameworkBundle] Throw runtime exception when trying to use asset-mapper while http-client is disabled | Q | A | ------------- | --- | Branch? | 6.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Issues | - | License | MIT Replaces #57219 and #57073 Commits ------- df133a9 [FrameworkBundle] Throw runtime exception when trying to use asset-mapper while http-client is disabled