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

Unable to resolve symlinked path in plugin on macOS #728

Open
tbradsha opened this issue Dec 9, 2024 · 2 comments
Open

Unable to resolve symlinked path in plugin on macOS #728

tbradsha opened this issue Dec 9, 2024 · 2 comments

Comments

@tbradsha
Copy link

tbradsha commented Dec 9, 2024

Quick summary

When creating a symlinking to the Jetpack plugin in wp-content/plugins, I get a PHP fatal.

Steps to reproduce

  1. Clone the Jetpack repo somewhere: https://github.com/Automattic/jetpack
  2. Build the plugin: jetpack build plugins/jetpack
  3. Create a symlink to the Jetpack plugin folder (e.g. ln -s /path/to/studio/site/wp-content/plugins /path/to/jetpack/repo/projects/plugins/jetpack
  4. Visit the site and activate the plugin.

What you expected to happen

The Jetpack plugin should run.

What actually happened

One gets fatal. Oddly it does resolve this path:

Users/jetpack/GitHub/jetpack/projects/plugins/jetpack/vendor/jetpack-autoloader/class-autoloader-handler.php

But not this one, which most certainly does exist:

/Users/jetpack/GitHub/jetpack/projects/plugins/jetpack/jetpack_vendor/automattic/jetpack-assets/actions.php

Fatal error: Uncaught Error: Failed opening required '/Users/jetpack/GitHub/jetpack/projects/plugins/jetpack/jetpack_vendor/automattic/jetpack-assets/actions.php' (include_path='.:') in /Users/jetpack/GitHub/jetpack/projects/plugins/jetpack/vendor/jetpack-autoloader/class-version-loader.php:109
Stack trace:
#0 /Users/jetpack/GitHub/jetpack/projects/plugins/jetpack/vendor/jetpack-autoloader/class-autoloader-handler.php(124): Automattic\Jetpack\Autoloader\jpf11009ded9fc4592b6a05b61ce272b3c_jetpackⓥ14_1\al5_0_0\Version_Loader->load_filemap()
#1 /Users/jetpack/GitHub/jetpack/projects/plugins/jetpack/vendor/jetpack-autoloader/class-autoloader.php(80): Automattic\Jetpack\Autoloader\jpf11009ded9fc4592b6a05b61ce272b3c_jetpackⓥ14_1\al5_0_0\Autoloader_Handler->activate_autoloader(Array)
#2 /Users/jetpack/GitHub/jetpack/projects/plugins/jetpack/vendor/autoload_packages.php(13): Automattic\Jetpack\Autoloader\jpf11009ded9fc4592b6a05b61ce272b3c_jetpackⓥ14_1\al5_0_0\Autoloader::init()
#3 /Users/jetpack/GitHub/jetpack/projects/plugins/jetpack/jetpack.php(144): require_once('/Users/jetpack/GitH...')
#4 /var/www/html/wp-settings.php(526): include_once('/Users/jetpack/GitH...')
#5 /var/www/html/wp-config.php(102): require_once('/var/www/html/w...')
#6 /var/www/html/wp-load.php(50): require_once('/var/www/html/w...')
#7 /var/www/html/wp-admin/admin.php(34): require_once('/var/www/html/w...')
#8 /var/www/html/wp-admin/index.php(10): require_once('/var/www/html/w...')
#9 {main} thrown in /Users/jetpack/GitHub/jetpack/projects/plugins/jetpack/vendor/jetpack-autoloader/class-version-loader.php on line 109

Impact

One

Available workarounds?

No and the app is unusable

Platform

Mac Silicon

Logs or notes

No response

@Robertght
Copy link

I believe this may be related: #20

I'm pinging @wojtekn for an extra look.

@Robertght Robertght added Triaged and removed Needs triage Ticket needs to be triaged labels Dec 15, 2024
@Robertght Robertght moved this from Needs Triage to Triaged in Automattic Prioritization: The One Board ™ Dec 15, 2024
@tbradsha
Copy link
Author

tbradsha commented Dec 19, 2024

Indeed, I had asked if I should comment in that issue or make a new one, but never got a reply. I'll note that supposedly symlinks were fixed for macOS (#510), but the comments in that other issue after that fix are hit-or-miss.

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

No branches or pull requests

3 participants