composer / satis

Simple static Composer repository generator - For a full private Composer repo use Private Packagist

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Latest update to composer.lock breaks composer install on PHP 7.4

smottt opened this issue · comments

commented

Describe the bug

The latest update to composer.lock locks psr/log to 2.0.0 which bumps the php requirement to 8.0+. But according to composer.json, PHP 7.3+ is required. If I remove composer.lock, everything installs perfectly fine.

Commit: 75b29ca#diff-f37acfaa6b11f575a9a6f41a75fa73a61d0f8ebc2c9b8cddc215d8aca10e44f5R676

To Reproduce
Run the following with PHP 7.4:

composer create-project composer/satis:dev-main

Outcome

Your lock file does not contain a compatible set of packages. Please run composer update.

  Problem 1
    - psr/log is locked to version 2.0.0 and an update of this package was not requested.
    - psr/log 2.0.0 requires php >=8.0.0 -> your php version (7.4.28) does not satisfy that requirement.
  Problem 2
    - symfony/deprecation-contracts is locked to version v3.0.0 and an update of this package was not requested.
    - symfony/deprecation-contracts v3.0.0 requires php >=8.0.2 -> your php version (7.4.28) does not satisfy that requirement.
  Problem 3
    - symfony/filesystem is locked to version v6.0.6 and an update of this package was not requested.
    - symfony/filesystem v6.0.6 requires php >=8.0.2 -> your php version (7.4.28) does not satisfy that requirement.
  Problem 4
    - symfony/finder is locked to version v6.0.3 and an update of this package was not requested.
    - symfony/finder v6.0.3 requires php >=8.0.2 -> your php version (7.4.28) does not satisfy that requirement.
  Problem 5
    - symfony/mime is locked to version v6.0.3 and an update of this package was not requested.
    - symfony/mime v6.0.3 requires php >=8.0.2 -> your php version (7.4.28) does not satisfy that requirement.
  Problem 6
    - symfony/process is locked to version v6.0.5 and an update of this package was not requested.
    - symfony/process v6.0.5 requires php >=8.0.2 -> your php version (7.4.28) does not satisfy that requirement.
  Problem 7
    - symfony/service-contracts is locked to version v3.0.0 and an update of this package was not requested.
    - symfony/service-contracts v3.0.0 requires php >=8.0.2 -> your php version (7.4.28) does not satisfy that requirement.
  Problem 8
    - symfony/string is locked to version v6.0.3 and an update of this package was not requested.
    - symfony/string v6.0.3 requires php >=8.0.2 -> your php version (7.4.28) does not satisfy that requirement.
  Problem 9
    - psr/log 2.0.0 requires php >=8.0.0 -> your php version (7.4.28) does not satisfy that requirement.
    - composer/xdebug-handler 3.0.3 requires psr/log ^1 || ^2 || ^3 -> satisfiable by psr/log[2.0.0].
    - composer/xdebug-handler is locked to version 3.0.3 and an update of this package was not requested.

Expected behavior
Composer installs the required packages.

commented

There is not much I can do about this. The .lock file is not leading. It's mostly just for the build processes. If you don't run the official satis docker container but instead run satis from git, then you can just ignore the .lock file or run composer update instead.

I feel like if we're gonna have tests for PHP 7.3 and 7.4 and say it's supported in the composer.json file then composer install and composer create-project should work out of the box on those versions. I can create a new pr for that separate from #691 to not conflate the composer dependencies with npm dependencies, so that that can be merged first

Because if the tests are relying on composer install, the CI checks would never pass for those versions if they can't resolve dependencies

commented

Should be resolved on main branch now.