How to track down plugin errors

AI-generated summary

Tracking Down Plugin Errors in Discourse

Bryan_Joseph encountered an error banner after installing multiple plugins and rebuilding the app. He tried removing plugins one by one to identify the issue, but was looking for a more efficient method.

Pfaffman suggested using the browser’s JavaScript inspector to find the errant theme component or plugin, and checking the logs for rails errors to infer the cause.

Bryan_Joseph found the issue to be with the image gallery plugin, but appreciated the suggestions for a better approach.

Stephen and Pfaffman recommended best practices for testing plugins, including using a staging copy and adding third-party plugins one at a time. Bryan_Joseph acknowledged the importance of test environments and agreed to implement these strategies.

I installed a bunch of plugins and then rebuilt the app. Now I am seeing this banner error:

I can play wack-a-mole by removing the plugin from the yml and then rebuilding but this is gonna take a while. I am wondering if there’s an easier way. I looked in the /logs but didn’t see anything good:
Screen Shot 2022-09-09 at Friday, September 9, 2022 8.57 PM

Should I look somewhere else for logs?

These are the plugins I am trying out:

I played enable/disable wack-a-mole and found out it was the image gallery plugin. I’d be interested in a better way to track it down though.

You can look in the Javascript inspector in your browser, it will usually give you the ID of the errant theme component (not sure about plugins). You can also look in the logs for rails errors and infer who to blame by the path of the files mentioned in the error.

Very good. I’ll look into these options. Thank you :blush:.

As a general rule unless your site hasn’t launched I would recommend you try new plugins on a staging copy beforehand.

Official plugins (the ones with the green tick) are usually more trustworthy, disabling the third party stuff first is usually a safe bet.

Good point. I love test environments. I should do that sooner rather than later.

And I’d generally recommend adding third party plugins one at a time.