Loading mu-plugin via composer throws 404 on some assets

Really weird issue where the plugin being required is an mu-plugin loaded via composer and is not loading all the assets for the plugin even though the plugin is working (mostly):

The important part of my composer.json file:

  "require": {
    "php": ">=5.4",
    "composer/installers": "~1.0.12",
    "johnpbloch/wordpress": "4.4.0",
    "vlucas/phpdotenv": "^1.1",
    "wpackagist-plugin/piklist": "dev-trunk",
    "wp-api/wp-api": "2.0-beta9.1"

  "extra": {
    "installer-paths": {
      "web/app/mu-plugins/{$name}/": ["type:wordpress-muplugin", "wpackagist-plugin/piklist", "wp-api/wp-api"],
      "web/app/plugins/{$name}/": ["type:wordpress-plugin"],
      "web/app/themes/{$name}/": ["type:wordpress-theme"]
    "wordpress-install-dir": "web/wp"

When I view the console for wp admin on a piklist plugin page, I get a ton of 404 errors - mostly having to do with icons, css and required jquery scripts for the piklist plugin.

Most of the functionality of the piklist plugin itself seems to work fine though. It’s only when I try to interact with it via it’s buttons or view it’s icons etc that it doesn’t work.

Any idea what’s happening?

Why is it 404? Where is it looking for the assets?

Sorry, should have mentioned that. It’s looking in the regular plugins directory.

Just to chime in that I saw the same thing, also using Piklist, which is what landed me here. It looks like all of the assets are pointing to the regular plugins directory so the images, js, css, etc never load correctly. I’ve moved it to my regular plugins list for now so I can at least keep working with both Piklist and Bedrock.

Piklist uses plugins_url without passing a path as the second parameter. This essentially hardcodes it to the plugins folder.

1 Like

Yep, just found the thread on their own forums about it. Looks like it’s on their radar at least: https://piklist.com/support/topic/pikilist-throwing-404-errors-when-moved-to-mu-plugins/

Thanks for the clearing up the confusion about it though.