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

OpenMage 20.4.0 / PHP 8.2.19 compatibility #1424

Closed
aminemekkidph2m opened this issue Jun 4, 2024 · 15 comments
Closed

OpenMage 20.4.0 / PHP 8.2.19 compatibility #1424

aminemekkidph2m opened this issue Jun 4, 2024 · 15 comments
Labels

Comments

@aminemekkidph2m
Copy link

Describe the bug

It looks like current version is not compatible with PHP 8.2 version.

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in phar:///usr/local/bin/magerun/vendor/symfony/yaml/Inline.php on line 49

Expected behaviour

Output not returning errors.

Steps to reproduce the issue

Running any command using PHP>8.2 version.
I'm currently using OpenMage version of Magento.

Technical details

  • Host Machine OS : Windows using WSL.
@cmuench
Copy link
Member

cmuench commented Jun 4, 2024

@aminemekkidph2m The actual stable version of n98-magerun does not support PHP 8.2.
It's not compatible.
Compatibility is still in progress. The next planned version is v3.0.0. The currently development version is related to the PR #1326
A version tested with PHP 8.1 is in the develop branch. You can try it by updating with n98-magerun.phar self-update --unstable.
I cannot guarantee that this will work for you. I personally do not work actively on the n98-magerun1 version.
Sadly there is not much progress here.

@sreichel
Copy link
Collaborator

sreichel commented Jun 5, 2024

@aminemekkidph2m please test unreleased v3.0 and let us know if the error is still there. I'll fix it in time.

(The linked PR is the "next step" that removes some outdated code.)

@sreichel
Copy link
Collaborator

sreichel commented Jun 5, 2024

@cmuench can you please check why the build failed for v3?

@cmuench
Copy link
Member

cmuench commented Jun 5, 2024

@cmuench can you please check why the build failed for v3?

@sreichel Looks like the self-update test job is failing. I found the same error in the issues of the Guzzle project. Maybe we need to upgrade the http client library.

@sreichel
Copy link
Collaborator

sreichel commented Jun 6, 2024

Tested some commands with v3 and php8.2 ... no errors.

@cmuench
Copy link
Member

cmuench commented Jun 6, 2024

@sreichel i was able to reproduce the issue in my ddev environment. I will try to fix it.

@cmuench
Copy link
Member

cmuench commented Jun 6, 2024

@sreichel A rebuild of the phar file fixed the download test job.

@cmuench
Copy link
Member

cmuench commented Jun 6, 2024

@sreichel I added OpenMage 20.1.0 and 20.9.0 to the Github Actions.
Currently the installation with the install command fails due to a missing Zend_Cache class.
Is there something special in the installation process in OpenMage >20.0?

@sreichel
Copy link
Collaborator

sreichel commented Jun 6, 2024

@cmuench i will test it later. Sounds similar to OpenMage/magento-lts#2961

Edit: in 20.1.0 lib/Zend was replaced with composer dependency.

@cmuench
Copy link
Member

cmuench commented Jun 7, 2024

@sreichel it's strange. We install via composer. It seems that the dependency is loaded correctly.

@sreichel
Copy link
Collaborator

sreichel commented Jun 7, 2024

@cmuench yeah, actions log seems okay. Local ddev works too.

Is it possible that vendor is outside of installDir "magento"?

Possible related: OpenMage/magento-lts#3226

I have no other idea so far and try to debug with https://nektosact.com

@cmuench
Copy link
Member

cmuench commented Jun 8, 2024

@sreichel I just allowed the Github Actions jobs running phpunit and bats to fail by setting continue-on-error: true.
In the CI/CD result it's now always OK but we can check the result log then.
And at least the installation can be tested for this versions until the issues is fixed in OpenMage.

@sreichel
Copy link
Collaborator

sreichel commented Jun 8, 2024

@cmuench provided a first fix over there.

Note: maybe we have to add some lines to clean EAV-cache. But lets wait with this.

@sreichel
Copy link
Collaborator

@aminemekkidph2m can we close it?

@sreichel
Copy link
Collaborator

Closed for no response. v3-dev works with php8.x.

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

No branches or pull requests

3 participants