8000 `composer update` pulls in packages ignoring `require.php` constraints · composer composer · Discussion #11164 · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

composer update pulls in packages ignoring require.php constraints #11164

Discussion options

You must be logged in to vote

from my experience composer always installs the highest version of packages that are compatible with the system's version of php and the ^7.4 || ^8.0 in the root package is used to print warnings if trying to run composer update on a machine without a satisfactory version:

the docs allude to this behaviour, implying that the php constraint is for the user:

php represents the PHP version of the user

i currently have to support packages for 7.4 and 8.1, and to work with this i install both versions of php locally and use the following commands:

php7.4 $(which composer) update
php8.1 $(which composer) update

it's worth noting that the php constraint is considered when requiring packages in…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
8000
2 replies
@herndlm
Comment options

@Seldaek
Comment options

Answer selected by herndlm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants
0