# 500 error on category view mobile due to knowledge base plugin

**URL:** https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996
**Category:** Support
**Created:** [January 29, 2020, 12:29am UTC](https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996 "2020-01-29T00:29:46Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![jonwgeorge](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jonwgeorge/32/167051_2.png) [@jonwgeorge](https://meta.discourse.org/u/jonwgeorge)
#### Post date: [January 29, 2020, 12:29am UTC](https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996/1 "2020-01-29T00:29:46Z")

</div>

I just launched a new discourse site and just noticed (at least via mobile) that I can’t get to the categories list.

Unable to confirm if desktop is doing same thing at this time as I’m away from my computer.

 ![image](https://global.discourse-cdn.com/meta/original/3X/5/1/5191d617b01fad803ef5c3e5e7bd8931cc543f26.png)

Site is [https://community.bcro.org](https://community.bcro.org) in case link is needed to troubleshoot.

---

<div class="post-metadata">

### Author: ![jonwgeorge](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jonwgeorge/32/167051_2.png) [@jonwgeorge](https://meta.discourse.org/u/jonwgeorge)
#### Post date: [January 29, 2020, 1:35am UTC](https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996/2 "2020-01-29T01:35:52Z")

</div>

Upon further investigation, this appears to be just related to mobile view.

---

<div class="post-metadata">

### Author: ![simon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/simon/32/339122_2.png) [@simon](https://meta.discourse.org/u/simon)
#### Post date: [January 29, 2020, 2:30am UTC](https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996/3 "2020-01-29T02:30:17Z")

</div>

I am finding the same problem when I open your site in mobile view. It even happens when I use [safe-mode](https://meta.discourse.org/t/how-to-use-discourse-safe-mode/53504) to open the site.

The errors I’m seeing in the console are:

```plaintext
GET https://community.bcro.org/categories.json 500
Error while processing route: discovery.categories

```

When I open the site in the desktop view, there are no errors on the categories page.

You can load the mobile view of your site on a desktop by going to `https://community.bcro.org/?mobile_view=1`. If you do this, and open your site’s error log page (Admin / Logs / Error Logs), you should see an error message that will give more details about what is going wrong. To filter the logs, deselect the `Debug`, `Info`, and `Warning` checkboxes from the bottom left of your logs page.

Let us know what you find in the logs.

---

<div class="post-metadata">

### Author: ![jonwgeorge](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jonwgeorge/32/167051_2.png) [@jonwgeorge](https://meta.discourse.org/u/jonwgeorge)
#### Post date: [January 29, 2020, 2:36am UTC](https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996/4 "2020-01-29T02:36:24Z")

</div>

When I visit the site I see this.

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:164:in `’

And here is the backtrace.

> <https://gist.github.com/jonwgeorge/a0c1987f01338fa533d98ad90cbc5dcc>

---

<div class="post-metadata">

### Author: ![simon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/simon/32/339122_2.png) [@simon](https://meta.discourse.org/u/simon)
#### Post date: [January 29, 2020, 2:50am UTC](https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996/5 "2020-01-29T02:50:24Z")

</div>

That seems to indicate that the problem is with the [discourse-knowledge-base](https://meta.discourse.org/t/knowledge-base-plugin/115288) plugin. You could try removing that plugin from your `app.yml` file, rebuilding the app, and see if that fixes the issue.

---

<div class="post-metadata">

### Author: ![jonwgeorge](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jonwgeorge/32/167051_2.png) [@jonwgeorge](https://meta.discourse.org/u/jonwgeorge)
#### Post date: [January 29, 2020, 2:53am UTC](https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996/6 "2020-01-29T02:53:27Z")

</div>

Will give that a try.. that would be unfortunate as it was **just** working…

---

<div class="post-metadata">

### Author: ![jonwgeorge](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jonwgeorge/32/167051_2.png) [@jonwgeorge](https://meta.discourse.org/u/jonwgeorge)
#### Post date: [January 29, 2020, 3:09am UTC](https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996/7 "2020-01-29T03:09:33Z")

</div>

Thanks for the assist @simon. That has cleared it up. I will be disabling this plugin for the foreseeable future and searching for a new option.

---

<div class="post-metadata">

### Author: ![simon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/simon/32/339122_2.png) [@simon](https://meta.discourse.org/u/simon)
#### Post date: [January 29, 2020, 3:18am UTC](https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996/8 "2020-01-29T03:18:29Z")

</div>

There is a good chance that the problem with the plugin will be easy to fix. You should report it here: [https://meta.discourse.org/t/knowledge-base-plugin/115288](https://meta.discourse.org/t/knowledge-base-plugin/115288).

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [February 28, 2020, 3:18am UTC](https://meta.discourse.org/t/500-error-on-category-view-mobile-due-to-knowledge-base-plugin/139996/9 "2020-02-28T03:18:52Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
