aspirepress / AspireUpdate

A plugin that allows for rewriting the URLs used to fetch updates from WordPress.org to some other endpoint
22 stars 10 forks source link

Playground server 500 on PHP 8.1/WP6.3 #58

Closed ipajen closed 3 days ago

ipajen commented 5 days ago
  1. Go to https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/aspirepress/AspireUpdate/refs/heads/playground-ready/assets/playground/blueprint.json

  2. In the playground settings choose WP 6.3 and PHP 8.1 and click apply settings

  3. playground gives "httpStatusCode": 500,

Expected that it should work to change to WP 6.3 and PHP 8.1

ipajen commented 5 days ago

Found this In the playground logs

27-Oct-2024 23:12:21 UTC] JavaScript Error: Theme twentytwentyfour could not be activated – WordPress exited with no error. Sometimes, when $_SERVER or site options are not configured correctly, WordPress exits early with a 301 redirect. Inspect the "debug" logs in the console for more details @https://playground.wordpress.net/assets/config-380f8aaf.js:55:111 [27-Oct-2024 23:12:21 UTC] JavaScript Error: Error when executing the blueprint step #7 ({"step":"installTheme","themeData":{"resource":"wordpress.org/themes","slug":"twentytwentyfour"}}) : Theme twentytwentyfour could not be activated – WordPress exited with no error. Sometimes, when $_SERVER or site options are not configured correctly, WordPress exits early with a 301 redirect. Inspect the "debug" logs in the console for more details @https://playground.wordpress.net/assets/config-380f8aaf.js:750:145943

Twenty Twenty-Four Came in WP 6.4, would it better to use 2023 theme instead as default ?

ipajen commented 5 days ago

Twenty Twenty-Two WP 5.9 Twenty Twenty-Three WP 6.1

namithj commented 5 days ago

This looks like a wordpress bug and not related to our plugin.

ipajen commented 5 days ago

This looks like a wordpress bug and not related to our plugin.

Can you explain how its a WP bug? As how I see it its that we use the twentytwentyfour in the blueprint that I guess its not compatible with older WP versions. For testing purpose it would be better to use the Twenty Twenty-Two so its possible to test with WP 5.9 and above and AP.

namithj commented 5 days ago

Its something related to 2024 and 2022 right, unrelated to our plugin or am I not following ?

ipajen commented 5 days ago

It’s we who define it in the blueprint

https://github.com/aspirepress/AspireUpdate/blob/9f14298cc8fa7778b9d6b157db8e7ad1c8b7f57d/assets/playground/blueprint.json#L48

  1. Twenty Twenty-Two: This theme was designed to work with WordPress 5.9 and above, given its full integration with the block editor features introduced in that version.

  2. Twenty Twenty-Three: This theme requires at least WordPress 6.1, aligning with updates in the block editor and design tools.

  3. Twenty Twenty-Four: The newest default theme, it is built to work with WordPress 6.4, taking advantage of all the latest tools and patterns in WordPress’s site editing features

namithj commented 5 days ago

@asirota should be able to update blueprint.json to reflect that, assigning to @asirota

asirota commented 5 days ago

Yup it may be a WordPress playgrounds issue. Need to investigate. I doubt it's a bug in our plugin.

asirota commented 5 days ago

2021 theme was good with 5.3 or later. That's sort of our minimum compatibility version I can put this into the blueprint.

https://wordpress.org/themes/twentytwentyone/

Agreed?

asirota commented 5 days ago

Fixed @ipajen - try AspireUpdate in WordPress playground with 2021 theme. 6.3 in the earliest WordPress supported. Maybe they'll make older WordPress available eventually to try. That would be nice.

ipajen commented 5 days ago

@asirota Ir would be better to use 2022 as https://wordpress.github.io/wordpress-playground/blueprints/examples/#load-an-older-wordpress-version

Note: the oldest supported WordPress version is 5.9.9, following the SQLite integration plugin.

if using to old version of theme it could be problematic when newer PHP or WP versions comes.

asirota commented 4 days ago

Our plugin supports WordPress 5.3 as per the README. It's trivial to upgrade the loaded theme in BLUEPRINT.json. The newer themes we encode may not work with the oldest WordPress version we support. The community has older than 5.9.9 installed for sure.

WordPress version 5 is used by 6.8% of all the websites whose content management system we know. This is 4.8% of all websites.

ipajen commented 4 days ago

Our plugin supports 5.4 as per the readme.

As if using 2021 you can’t still test WP 5.3-5.8 in playground.

asirota commented 4 days ago

That's ok. Our user base is the concern. WordPress playgrounds set 5.9.9 to be in sync with WordPress official support, but you can manually invoke an older version just fine using the query param API or modifying the blueprint to force a pre 5.9.9 version of WordPress to be loaded. They just don't want to offer an older version to push devs to encourage upgrading to 5.9.9 or later.

ipajen commented 4 days ago

Note: the oldest supported WordPress version is 5.9.9, following the SQLite integration plugin.

https://wordpress.github.io/wordpress-playground/blueprints/examples/#load-an-older-wordpress-version

so if I understand you correctly it’s possible to use WP 5.3 on playground ?

asirota commented 4 days ago

Yes. Using the query parameter or a blueprint.JSON change. Docs available on WordPress playground website.

Alex Sirota, PMP PGP Public Key https://bit.ly/asirotapgp Director at NewPath Consulting https://newpathconsulting.com/

Start a free WildApricot trial. https://register.wildapricot.com/?refcode=M6QF7KFQ6M Try Make.com for free. https://www.make.com/en/register?pc=newpath1

On Mon, Oct 28, 2024 at 2:24 PM Jarko Piironen @.***> wrote:

Note: the oldest supported WordPress version is 5.9.9, following the SQLite integration plugin.

https://wordpress.github.io/wordpress-playground/blueprints/examples/#load-an-older-wordpress-version

so if I understand you correctly it’s possible to use WP 5.3 on playground ?

— Reply to this email directly, view it on GitHub https://github.com/aspirepress/AspireUpdate/issues/58#issuecomment-2442316348, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADP3FQWPYYZS6RFFHWKIZDZ5ZXLFAVCNFSM6AAAAABQWH4G2GVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDINBSGMYTMMZUHA . You are receiving this because you were mentioned.Message ID: @.***>

asirota commented 3 days ago

Looks like playground indeed only works with 5.9.9 of wordpress or later, I will change the blueprint.json to use 2022 theme (twentytwentytwo). Committed to playground-ready.