Plugin No Longer Loading or Visible

My plugin, although in the plugins directory of my Discourse instance, is no longer loaded or displaying in the Admin interface.

I’m using Docker in my Discourse development environment.

I previously had problems with symlinking my plugin, which led me to rename the symlink, then rename the directory, then eliminate the symlink entirely and move the whole directory into /plugins.

I rebooted my laptop and restarted the dev server, and now Discourse has no knowledge that my plugin exists at all. It doesn’t display in the admin interface, and Discourse.plugins.map(&:name) in d/rails c doesn’t display my plugin. I’ve tried clearing cache with d/rake assets:clobber tmp:clear and restarting the servers with d/rails s and d/ember-cli.

It’s not an invalid directory structure, file permissions, plugin.rb, or any of that. The plugin was working just fine this morning. The only things I’ve modified since then, according to git, are a glimmer component and a scss file.

Is there anything else I can do to reset state? What could cause Discourse to not detect a plugin?

I wonder if the docker container didn’t fare well with all the directory renaming and changing from a symlink to a regular folder.

I ran docker rm -f /discourse_dev and d/cleanup. This reclaimed nearly 30 GB.
Ran d/boot_dev. Ran d/rails s and d/ember-cli.

Now my plugin displays again. Ok, that solved the problem, and it looks like some kind of caching at the docker layer was the culprit.

1 Like