Skip to content
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

Does not install with Composer w/o warnings/errors (PHP 8) #202

Open
jimbonator opened this issue Jun 14, 2022 · 5 comments
Open

Does not install with Composer w/o warnings/errors (PHP 8) #202

jimbonator opened this issue Jun 14, 2022 · 5 comments

Comments

@jimbonator
Copy link

AspectMock 4.1.1 won't install cleanly under PHP 8 with Composer:

$ composer update 
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Root composer.json requires codeception/aspect-mock 4.1.1 -> satisfiable by codeception/aspect-mock[4.1.1].
    - codeception/aspect-mock 4.1.1 requires php ^7.4 -> your php version (8.1.2) does not satisfy that requirement.

The only way I can get it to install without errors is to use Composer's --ignore-platform-reqs option.

Although there are problems with goaop/parser-reflection under PHP 8 (see goaop/framework#466), I believe AM itself will work without issue under the newer PHP versions (other than the problem I reported in #201).

I believe changing this composer.json line would be sufficient:

-        "php": "^7.4",
+        "php": ">=7.4",
@Naktibalda
Copy link
Member

There is no point to claim that AspectMock support PHP 8, if underlying library doesn't support it.

@jimbonator
Copy link
Author

I've submitted a patch to goaop/parser-reflection: goaop/parser-reflection#121

@votetake
Copy link

But it is still in open status

@jimbonator
Copy link
Author

jimbonator commented May 2, 2024

The parser-reflection ticket is closed now.

@marcovtwout
Copy link
Contributor

marcovtwout commented Jul 9, 2024

The message in the README on https://github.com/goaop/parser-reflection suggests that library is deprecated, but there have been many updates in the last few months. The dev versions works in one of my projects on PHP 8.2.

I've submitted a PR for preliminary PHP 8.2 support: #210

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants