-
Notifications
You must be signed in to change notification settings - Fork 266
PHP 7.3 polyfill is not necessary because PHP 7.4 is required #1167
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
"type": "path", | ||
"url": "../", | ||
"symlink": true | ||
"name": "mongodb/mongodb-benchmark", |
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.
Fix indentation.
"replace": { | ||
"symfony/polyfill-php80": "*", | ||
"symfony/polyfill-php81": "*" | ||
}, |
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.
The benchmark sub-project requires PHP 8.1, I disable the installation of this polyfills.
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.
Is this the preferred method to avoid installing polyfills that are indirect dependencies? I suppose in an ideal world the polyfill packages would have some way to note that they're redundant for newer PHP versions (an inverse of requires
), but there's no composer.json
syntax for that.
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.
Strictly speaking, it's not necessary to prevent installing the polyfills. The polyfill itself checks if the function exists and doesn't register itself if it does.
That said, I'm fine including these directives here until we can use PHP 8.1.
"replace": { | ||
"symfony/polyfill-php80": "*", | ||
"symfony/polyfill-php81": "*" | ||
}, |
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.
Is this the preferred method to avoid installing polyfills that are indirect dependencies? I suppose in an ideal world the polyfill packages would have some way to note that they're redundant for newer PHP versions (an inverse of requires
), but there's no composer.json
syntax for that.
I think it has been forgotten in #1128
get_debug_type
from PHP 8.0 polyfill is usedarray_is_list
from PHP 8.1 polyfill is usedThe benchmark sub-project requires PHP 8.1, I disable the installation of this polyfills.