-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[PhpUnitBridge] vendor weak mode fails #21980
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
Comments
Both entries are supposed to be added just below : https://github.com/symfony/symfony/blob/master/src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler.php#L100 Can you please debug that part ? |
Indeed I didn't see it. There is two things:
|
Not sure why, but I don't reproduce this bug… what do you reckon should be done ?
|
To be honest, I don't even understand what you mean by resolved… when I try the function, it does add the two entries in my case. |
You said you are upgrading EDIT: I see that the symfony package on packagist does not replace |
Add the 2 entries unconditionally, we don't really care.
I mean that the |
demo here |
You have both
EDIT: I do reproduce the issue when using |
The issue goes away when using a "real" environment variable : |
Well, I just installed the app with the Symfony installer :)
I don't think it's a problem, but in your case I think you get the right
mode because you declare the environment variable. In mine its objected by
PhpUnit which happens later (after the error handler registration).
…On Mon, 13 Mar 2017 at 07:29, Grégoire Paris ***@***.***> wrote:
The issue goes away when using an environment variable : SYMFONY_DEPRECATIONS_HELPER=weak_vendors
vendor/bin/simple-phpunit.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#21980 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AE76geG7erDXLPcY78r04a-jmUOiptqPks5rlPBDgaJpZM4MatCt>
.
|
So… you found a bug in simple-phpunit? |
This PR was merged into the 3.3-dev branch. Discussion ---------- Stop relying on the $mode argument When registering the error handler, simple-phpunit might be used, and in that case, the bootstrap process will not have environment variables defined inside phpunit.xml.dist . This means `$mode` might differ when registering the error handler, and when an error is triggered. This raises a question: should the $mode argument be removed to avoid similar errors in the future? | Q | A | ------------- | --- | Branch? | master | Bug fix? | yes | New feature? | no | BC breaks? | yes/no | Deprecations? | yes/no <!-- don't forget updating UPGRADE-*.md files --> | Tests pass? | yes/no | Fixed tickets | #21980 | License | MIT | Doc PR | n/a <!-- - Bug fixes must be submitted against the lowest branch where they apply (lowest branches are regularly merged to upper ones so they get the fixes too). - Features and deprecations must be submitted against the master branch. - Please fill in this template according to the PR you're about to submit. - Replace this comment by a description of what your PR is solving. --> Commits ------- 0d180d5 Stop relying on the $mode argument
#21539 results in an error on my end after upgrading
symfony/symfony
to^3.3.@dev
.From what I see the error seems to come from https://github.com/symfony/symfony/blob/master/src/Symfony/Bridge/PhpUnit/DeprecationErrorHandler.php#L88 where it should be:
PhpUnit config:
/cc @greg0ire
The text was updated successfully, but these errors were encountered: