If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

Freemarker errors for Showfor section of many KB articles



support.mozilla.org - Lithium
Knowledge Base Content
7 months ago
7 months ago


(Reporter: guigs [guigs] PST (please needinfo me!), Unassigned)



(Whiteboard: [1st2weeks])


(6 attachments)

Created attachment 8837201 [details]


As an Admin, this page shows errors in the right hand column, where the show for items are normally shown. (See showforbug.png attached)

So far, it is just that article, titled "Answering Questions in the Support Forum", in the Contributor Knowledge Base TKB under the Contributor Resources Category.

Comment 1

7 months ago
I also see those showfor errors in other Documents Archive articles, such as https://support.mozilla.org/t5/Documents-Archive/How-do-I-create-a-screenshot-of-my-problem/ta-p/7064
I posted more information in that article's Comments section earlier today. 

That article shouldn't be in the Documents archive, by the way, since it's a "How to"  article to help users create a screenshot to post to their support question. Related discussion: https://support.mozilla.org/t5/Knowledge-Base-L10n-Discussions/quot-Create-a-screenshot-quot-article-draft-needs-review/m-p/1362337#U1362337

Comment 2

7 months ago
I looked through https://support.mozilla.org/t5/Documents-Archive/tkb-p/documents-archive and so far, all of the articles I checked show a FreeMarker template error.
Whiteboard: [1st2weeks]
needinfo'ing tyson and scott

Tyson and Scott could one of you or the other fine lithium folks fix this please?
Flags: needinfo?(tyson.nunemacher)
Flags: needinfo?(scott.riley)

Comment 4

7 months ago
Another example was posted today in IRC #sumo:


Comment 5

7 months ago
I looked through https://support.mozilla.org/t5/Bookmarks-and-Tabs/tkb-p/Bookmarks-Tabs-fireFox and all of the articles I checked show a FreeMarker template error.
Severity: normal → critical


7 months ago
Summary: Freemarker errors for Showfor section of a particular article → Freemarker errors for Showfor section of many KB articles

Comment 6

7 months ago
Created attachment 8837736 [details]

Here is a screenshot of the error when I'm not signed in or when I'm signed in with a "New Contributor" profile.  Notice that the "Create a screenshot on Windows" section is not displayed, even though I'm on Windows 7.
https://support.mozilla.org/t5/How-To/Page-Info-window/ta-p/15132 Another one flagged in abuse reports.

Comment 8

7 months ago
(In reply to rmcguigan from comment #7)
> https://support.mozilla.org/t5/How-To/Page-Info-window/ta-p/15132 Another
> one flagged in abuse reports.

Did you mean to post this to another bug?

Comment 9

7 months ago
(from comment #8)
> (In reply to rmcguigan from comment #7)
> > https://support.mozilla.org/t5/How-To/Page-Info-window/ta-p/15132 Another
> > one flagged in abuse reports.
> Did you mean to post this to another bug?

Sorry, I see that the above page shows a FreeMarker template error.  So do all articles in the "How to" and "Troubleshooting" archives containing redirects for renamed articles:

Comment 10

7 months ago
Created attachment 8838439 [details]

I was looking through the How To archive and noticed Escalation Guidelines (a "How to Contribute" article).  Like other articles in an archive location, this one showed the FreeMarker error.  As a test, I moved the article back to the Contributors KB where it was originally, and the error is gone: 

So, it looks like these errors are the result of moving KB articles to the various archive locations.

Comment 11

7 months ago
Created attachment 8838440 [details]


7 months ago
Severity: critical → normal

Comment 12

7 months ago
Created attachment 8838849 [details]

(from comment #1)
> https://support.mozilla.org/t5/Documents-Archive/How-do-I-create-a-screenshot-of-my-problem/ta-p/7064
I moved that article out of the archived location. I no longer see the error in the new location.

By the way, the FreeMarker template error isn't limited to articles in archived locations.  I also see it when selecting one of the unpublished revisions in the KB article dashboard at https://support.mozilla.org/t5/tkb/dashboardpage/category-id/Mozilla-EN

Comment 13

7 months ago
Created attachment 8839222 [details]

Articles in these "Contributor Resources" locations also show a FreeMarker template error:

Common Responses

Comment 14

7 months ago
Please check the JSON object for those nodes.  For example, the one here https://support.mozilla.org/t5/bizapps/bizappspage/tab/community%3Aadmin%3Asystem%3Asettings-list-editor/node-display-id/tkb-board%3Affandroid_template is not valid which will cause the widget to display an error.

Testing via http://jsonlint.com/
Flags: needinfo?(scott.riley) → needinfo?(jsavage)
scott you right ! 

somehow (copy and paste error?):

"visible": true

was changed to

"visible": !0

which is very weird
Got it to work EXCEPT for the unpublished revisions dashboard in comment 12 using the showfor.json here:

Full details on how I made this showfor.json:

Scott, Joni, Madalina please tell me where the showfor.json is for "unpublished revisions in the KB article dashboard" at https://support.mozilla.org/t5/tkb/dashboardpage/category-id/Mozilla-EN and then I will fix comment 12 too!
Flags: needinfo?(scott.riley)
Flags: needinfo?(mana)
fixed, forgot Mozilla Support Community :: Mozilla Support - English, thanks to Joni for her help!
Last Resolved: 7 months ago
Flags: needinfo?(tyson.nunemacher)
Flags: needinfo?(scott.riley)
Flags: needinfo?(mana)
Flags: needinfo?(jsavage)
Resolution: --- → FIXED


7 months ago
Component: Lithium Migration → Knowledge Base Content
Product: support.mozilla.org → support.mozilla.org - Lithium
You need to log in before you can comment on or make changes to this bug.