Skip to content

PHP version requirement contradiction. #105

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

Closed
neoacevedo opened this issue Aug 14, 2024 · 8 comments
Closed

PHP version requirement contradiction. #105

neoacevedo opened this issue Aug 14, 2024 · 8 comments
Labels
bug Something isn't working

Comments

@neoacevedo
Copy link

neoacevedo commented Aug 14, 2024

There is a contradiction in the dependences:

codeception/module-yii2[1.1.0, ..., 1.1.1] require php >=5.6.0 <8.0 -> your php version (8.0.8) does not satisfy that requirement.
codeception/lib-innerbrowser[4.0.0, ..., 4.0.3] require php ^8.1 -> your php version (8.0.8) does not satisfy that requirement.

The module itself requires a PHP < 8.0 but its dependence, lib-innerbrowser requires a version >= 8.1

I'm trying to install this module in the yii2 app basic template, but the PHP version requirement is weird. If I try with PHP >= 8.0 the results are the same.

Using version ^1.1 for codeception/module-yii2
./composer.json has been updated
Running composer update codeception/module-yii2
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - codeception/module-yii2[1.1.6, ..., 1.1.7] require codeception/lib-innerbrowser ^3.0 -> satisfiable by codeception/lib-innerbrowser[3.0.0, ..., 3.1.3].
    - codeception/module-yii2[1.1.8, ..., 1.1.10] require codeception/lib-innerbrowser ^3.0 | ^4.0 -> satisfiable by codeception/lib-innerbrowser[3.0.0, ..., 3.1.3, 4.0.0, 4.0.1, 4.0.2, 4.0.3].
    - codeception/module-yii2[1.1.0, ..., 1.1.1] require php >=5.6.0 <8.0 -> your php version (8.0.8) does not satisfy that requirement.
    - codeception/module-yii2[1.1.2, ..., 1.1.5] require codeception/codeception ^4.0 -> found codeception/codeception[4.0.0, ..., 4.2.2] but it conflicts with your root composer.json require (^5.1).
    - codeception/lib-innerbrowser 3.0.0 requires symfony/browser-kit ^4.4 || ^5.4 || ^6.0 -> found symfony/browser-kit[v4.4.0, ..., v4.4.44, v5.4.0, ..., v5.4.40, v6.0.0, ..., v6.4.8] but it conflicts with your root composer.json require (>=2.7 <=4.2.4).
    - codeception/lib-innerbrowser[3.0.1, ..., 3.1.3] require symfony/browser-kit ^4.4.24 || ^5.4 || ^6.0 -> found symfony/browser-kit[v4.4.24, ..., v4.4.44, v5.4.0, ..., v5.4.40, v6.0.0, ..., v6.4.8] but it conflicts with your root composer.json require (>=2.7 <=4.2.4).
    - codeception/lib-innerbrowser[4.0.0, ..., 4.0.3] require php ^8.1 -> your php version (8.0.8) does not satisfy that requirement.
    - Root composer.json requires codeception/module-yii2 ^1.1 -> satisfiable by codeception/module-yii2[1.1.0, ..., 1.1.10].

Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.

Installation failed, reverting ./composer.json and ./composer.lock to their original content.
@samdark samdark added the bug Something isn't working label Aug 14, 2024
@samdark
Copy link
Member

samdark commented Aug 14, 2024

@neoacevedo do you have time to do a pull request correcting versions? Thanks.

@Naktibalda
Copy link
Member

Your project has requirement for an old version of symfony/browser-kit

found symfony/browser-kit[v4.4.24, ..., v4.4.44, v5.4.0, ..., v5.4.40, v6.0.0, ..., v6.4.8] but it conflicts with your root composer.json require (>=2.7 <=4.2.4).

@Naktibalda
Copy link
Member

Oh, it comes from very interesting version constraint in basic template

"symfony/browser-kit": "^6.0 || >=2.7 <=4.2.4"

back to @samdark

@neoacevedo
Copy link
Author

@neoacevedo do you have time to do a pull request correcting versions? Thanks.

I will try but I'm so noob on it.

@Naktibalda
Copy link
Member

@neoacevedo If you haven't figured it out yet, my advice is to completely remove symfony/browser-kit from composer.json of your project.

@neoacevedo
Copy link
Author

Interesting, that symfony package is the root cause.

@samdark
Copy link
Member

samdark commented Aug 15, 2024

Interesting, that symfony package is the root cause.

It is caused by composer.json in Yii2's basic/advanced templates. Fix is as @Naktibalda suggested.

samdark added a commit to yiisoft/yii2-app-basic that referenced this issue Sep 7, 2024
@samdark
Copy link
Member

samdark commented Sep 7, 2024

@samdark samdark closed this as completed Sep 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants