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

PHP8 compatibility and installation via Composer #16881

Closed
sboerrigter opened this issue Apr 12, 2021 · 7 comments · Fixed by #17536
Closed

PHP8 compatibility and installation via Composer #16881

sboerrigter opened this issue Apr 12, 2021 · 7 comments · Fixed by #17536

Comments

@sboerrigter
Copy link

sboerrigter commented Apr 12, 2021

Hi There! 👋

Are the "WordPress SEO" and "WordPress SEO Premium" plugins compatible with PHP 8?

I see that the version constraints in composer.json are set to "^5.6.20||^7.0", so I cannot install these plugins via Composer. Can you please update these version constraints if the plugins are compatible with PHP 8? And if they are not, is there an expected date when they will be?

Thanks in advance!

Used versions

  • WordPress version: 5.7
  • Yoast SEO version: 16.1.1
  • Yoast SEO Premium version: 16.1
  • PHP version: 8.0.3
@Djennez
Copy link
Member

Djennez commented Apr 12, 2021

Hi @sboerrigter . The plugins themselves are compatible with PHP 8.0. However, the composer process isn't and still needs to be ran with PHP 7.x. I believe it's something that's still being worked on and I'm not really sure anymore what the reason(s) are/were. But they were substantial enough that we couldn't just change the requirements in the json file.

@huubl
Copy link

huubl commented Aug 6, 2021

Any update on this?

@csanadkiss-seon
Copy link

Are there any updates on this?

@zmonteca
Copy link

Any update on this?

PHP 8.0.11 (cli) (built: Sep 23 2021 21:26:06) ( NTS )
Copyright (c) The PHP Group
Zend Engine v4.0.11, Copyright (c) Zend Technologies
    with Zend OPcache v8.0.11, Copyright (c), by Zend Technologies
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - yoast/wordpress-seo-premium[16.0, ..., 16.9.0] require php ^5.6.20||^7.0 -> your php version (8.0.11) does not satisfy that requirement.
    - Root composer.json requires yoast/wordpress-seo-premium ^16.0 -> satisfiable by yoast/wordpress-seo-premium[16.0, ..., 16.9.0].

@Djennez
Copy link
Member

Djennez commented Sep 27, 2021

The plugin still needs to be build on 7.x. There are no updates on PHP 8.0 progression.

And just to clarify for others; the plugin does work on PHP8. It's the composer building that needs to be done on 7.x.

@zmonteca
Copy link

Thanks.

That's a big odd....build on 7.x for use on 8.x?

FWIW, that creates a LOT of work when doing auto-deployments. It would be great if you could get on with testing and building via standard methods.

PHP 8.x has officially been out for a year now...

@zmonteca
Copy link

As an addition for anyone that this is affecting, there's a workaround in composer that I was not privy to.

Given that @Djennez said that Yoast is PHP 8.0 compatible, I felt comfortable doing a platform override.

Adding this to my composer worked perfectly.

    "config": {
        "platform": {
            "php": "7.4"
        }
    }

@Djennez Djennez linked a pull request Oct 21, 2021 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants