You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I think that's because the debug clients are only registered in the HttpClientPass which is excecuted after the extension.
Not really sure how this is supposed to work.
Moreover, I don't even see how that feature is supposed to work anyway:
How does setClass() help here? The http client services are created using the HttpClient::create() factory so without resetting the factory, this here cannot work?
Pinging @GaryPEGEOT as the original author of that feature, maybe I missed something completely :)
The text was updated successfully, but these errors were encountered:
…or mock factory (GaryPEGEOT)
This PR was squashed before being merged into the 5.2 branch.
Discussion
----------
[HttpClient] Use decoration instead of class replacement for mock factory
| Q | A
| ------------- | ---
| Branch? | 5.2
| Bug fix? | yes
| New feature? | no
| Deprecations? | no
| Tickets | Fix#39266
| License | MIT
Commits
-------
9a9823c [HttpClient] Use decoration instead of class replacement for mock factory
Symfony version(s) affected: 5.2.0
Description
Whenever I want to use the new
framework.http_client.mock_response_factory
option introduced in #35893, I get the following error:How to reproduce
Configure
and let the container build.
Possible Solution
I think that's because the debug clients are only registered in the
HttpClientPass
which is excecuted after the extension.Not really sure how this is supposed to work.
Moreover, I don't even see how that feature is supposed to work anyway:
symfony/src/Symfony/Bundle/FrameworkBundle/DependencyInjection/FrameworkExtension.php
Lines 2073 to 2077 in 42f440e
How does
setClass()
help here? The http client services are created using theHttpClient::create()
factory so without resetting the factory, this here cannot work?Pinging @GaryPEGEOT as the original author of that feature, maybe I missed something completely :)
The text was updated successfully, but these errors were encountered: