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

Upgrade @php-wasm and related dependencies to 0.7.20 #154

Closed
wants to merge 2 commits into from

Conversation

derekblank
Copy link
Contributor

Related to #119

Proposed Changes

Support for WebP images was added to WordPress-Playground in 0.7.20 packages. Upgrading @php-wasm and related dependencies should allow users to upload WebP files.

Upgrades the following related dependencies to 0.7.20:

  • @php-wasm/node
  • @php-wasm/universal
  • @wp-playground/blueprints

Testing Instructions

(TBD)

TODO

Pre-merge Checklist

  • Have you checked for TypeScript, React or other console errors?

@derekblank
Copy link
Contributor Author

When running these updated dependency changes locally, I encounter the following error when starting or creating a site:

Starting new session
Error occurred in handler for 'startServer': TypeError: php.setPhpIniEntry is not a function
    at ~/studio/.webpack/main/siteServerProcess.js:54038:13
    at Generator.next (<anonymous>)
    at fulfilled (~/studio/.webpack/main/siteServerProcess.js:53994:58)
Sentry Logger [error]: Transport disabled

Indeed in the WordPress-Playground CHANGELOG I note this breaking change related to setPhpIniEntry:

@sejas I can't quite tell if the "Remaining Work" section in WordPress/wordpress-playground#1423 means there is still work needed in WordPress-Playground to resolve the breaking change related to setPhpIniEntry.

If that's the case, we can hit pause on this PR until those changes have been completed. If not, do you note if there's any further dependency updates needed in Studio to resolve this breaking change? Perhaps we would need to update vendor/wp-now as well? Any further thoughts on the approach are welcome. 🙇

@sejas
Copy link
Member

sejas commented May 23, 2024

It seems we will need to refactor vendor/wp-now to avoid using setPhpIniEntry. I can try to setup a PR in wp-now repository that will be easier to migrate here 👍

@derekblank
Copy link
Contributor Author

I can try to setup a PR in wp-now repository that will be easier to migrate here 👍

That sounds great. Let me know if I can help review.

@wojtekn
Copy link
Contributor

wojtekn commented May 31, 2024

It seems we will need to refactor vendor/wp-now to avoid using setPhpIniEntry. I can try to setup a PR in wp-now repository that will be easier to migrate here 👍

@derekblank @sejas I checked it, and it seems that wp-now doesn't use the setPhpIniEntry method. It was something we added in forked wp-now in the Studio repository.

Should we continue with this PR and plan to switch from using setPhpIniEntry to setPhpIniEntries?

@derekblank
Copy link
Contributor Author

Should we continue with this PR and plan to switch from using setPhpIniEntry to setPhpIniEntries?

I agree. I don't have much context for why wp-now is included as a separate vendored copy, but I imagine it was either to introduce custom code changes to the library, or perhaps to fence the library off from receiving updates to keep Studio development stable.

(Lacking this context) It seems like it'd be more efficient to use wp-now directly, either as a node dependency or a git submodule, and keep Studio up-to-date with wp-now changes. Is there anything preventing this?

@wojtekn
Copy link
Contributor

wojtekn commented Jun 3, 2024

@derekblank we decided to fork wp-now, here is more context: https://github.com/Automattic/local-environment/pull/46

@sejas
Copy link
Member

sejas commented Jul 26, 2024

Closing in favor of #392

@sejas sejas closed this Jul 26, 2024
@sejas sejas deleted the upgrade/php-wasm-node-0.7.20 branch July 26, 2024 22:39
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

Successfully merging this pull request may close these issues.

None yet

3 participants