-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
Have weak_vendors ignore deprecations from outside #24864
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
Have weak_vendors ignore deprecations from outside #24864
Conversation
Wait wut? It passes on some versions of php??? I thought it wouldn't pass at all... |
Nop, just that some version of PHP are skipped for pull-requests. See the logs of the successful ones. |
Thanks @sroze , things make sense again thanks to you! |
3f43275
to
d2371fa
Compare
Ok so now the build only fails on 7.2... with deps=low |
Could it be become of the |
As a bug fix, it should be merged on 3.3: https://symfony.com/roadmap?version=3.3#checker Should not be? |
That's correct, let me rebase. |
d2371fa
to
8f8d5f4
Compare
Tests are failing probably because
See #24867 (comment) I'm afraid there is nothing I can do about that. Is there hope to get this merged nonetheless? |
@@ -75,9 +75,12 @@ public static function register($mode = 0) | |||
} | |||
} | |||
} | |||
$path = realpath($path) ?: $path; | |||
$realPath = realpath($path); | |||
if (false === $realPath && '-' !== $path) { |
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.
I think -
has changed on 7.2, the string is different
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.
Dang, good catch! I knew this was a bit fragile but don't know what else to use, will have to give it more thought.
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.
Thanks to docker I now know this could be "Standard input code"
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.
Can't think of a less fragile solution though.
8f8d5f4
to
d378244
Compare
Not sure it's that string you were thinking about @nicolas-grekas : here is the change : php/php-src@3ed8b7a , and it does not change from |
Ok so now I am sure, tried the code with:
And then confirmed with some |
I just confirmed the tests pass on 5.5 by using
|
fabbot seems stuck, let's close and reopen |
Please review again |
ping @nicolas-grekas |
d378244
to
6580c38
Compare
I added a script to regenerate the phar, so that it's easier to understand or maintain. |
6580c38
to
f776108
Compare
phar:// and eval() can execute code that may or may not come from the vendors.
f776108
to
9ce0ae2
Compare
Thank you @greg0ire. |
This PR was merged into the 3.3 branch. Discussion ---------- Have weak_vendors ignore deprecations from outside phar:// and eval() can execute code that may or may not come from the vendors. | Q | A | ------------- | --- | Branch? | 3.3 | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | not yet | Fixed tickets | #24853 | License | MIT I haven't managed to get the phar test to pass yet, but before I do, is it ok for me to commit a test phar in Symfony? I'm thinking trust issues? Although the phar is almost plain text. ~~Next, I'm stuck because it looks like symfony does not know how to load classes anymore... should I somehow load `vendor/autoload.php` from the phar or something like that?~~ solved, had nothing to do with that. Commits ------- 9ce0ae2 Have weak_vendors ignore deprecations from outside
This reverts commit e103e32. The issues with this mode have been fixed and are released. See symfony/symfony#24864
This reverts commit e103e32. The issues with this mode have been fixed and are released. See symfony/symfony#24864
phar:// and eval() can execute code that may or may not come from the vendors.
I haven't managed to get the phar test to pass yet, but before I do, is it ok for me to commit a test phar in Symfony? I'm thinking trust issues? Although the phar is almost plain text.
Next, I'm stuck because it looks like symfony does not know how to load classes anymore... should I somehow loadsolved, had nothing to do with that.vendor/autoload.php
from the phar or something like that?