The software powering this discussion forum encountered an unexpected problem

You can just go to /logs in the URL btw (a bit quicker than logging in via terminal, but you’ll soon need to do that!)

Do you see this error?:

StandardError (Attempting to access a non preloaded custom field, this is disallowed to prevent N+1 queries.) /var/www/discourse/app/models/concerns/has_custom_fields.rb:158:in []

This has been happening to a lot of sites recently due to a core change which is causing several plugins to break the build. Many plugins have been updated to fix this including Topic List Previews, Events Plugin, Discourse-Solved and Custom Layouts plugins.

First I would perform a complete rebuild to pick up all the updates, then if that doesn’t resolve it I would remove all plugins that don’t have explicit fixes for this and rebuild.

7 Likes