-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[HttpClient] Declare $active
first to prevent weird issue
#32989
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
$active
first to prevent weird issue$active
first to prevent weird issue
Would using |
I don't have the time for now, I will check it out this evening. |
Huh, so I don't understand why. It's a variable declared in a reference so it should be ok... Maybe because of a weird PHP configuration, it fails? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(issue in tests was unrelated to this PR and has been fixed in #33005)
Thank you @Kocal. |
…e (Kocal) This PR was squashed before being merged into the 4.3 branch (closes #32989). Discussion ---------- [HttpClient] Declare `$active` first to prevent weird issue | Q | A | ------------- | --- | Branch? | 4.3 | Bug fix? | yes | New feature? | no <!-- please update src/**/CHANGELOG.md files --> | BC breaks? | no <!-- see https://symfony.com/bc --> | Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files --> | Tests pass? | - <!-- please add some, will be required by reviewers --> | Fixed tickets | #32833 <!-- #-prefixed issue number(s), if any --> | License | MIT | Doc PR | no In some undefined cases we can have the following error while using the WebTestCase/CurlHttpClient in PHPUnit:  This is really weird because `$active` is a reference and so it does not need to be declared before, but doing that fixes the issue. (#32833 (comment)) I can't add tests because we were not able to reproduce the issue... Commits ------- ba030f0 [HttpClient] Declare `$active` first to prevent weird issue
In some undefined cases we can have the following error while using the WebTestCase/CurlHttpClient in PHPUnit:

This is really weird because
$active
is a reference and so it does not need to be declared before, but doing that fixes the issue. (#32833 (comment))I can't add tests because we were not able to reproduce the issue...