</noinclude> gets parsed within <pre></pre> in templates, causing explanatory text to be transcluded into pages. In the following example, everything after </pre> and </noinclude> incorrectly gets transcluded wherever the template is used. The only workaround is to use <includeonly></includeonly> instead of <onlyinclude></onlyinclude>, which should not be necessary, and can cause problems if that is not how the template was designed.
This problem arises from the best-practice of encapsulating templatized category tags within no-include tags so that category transclusion will happen only once, not every time some other page uses the page that has a category template.
Here's the example:
<noinclude>
This is a category template for quickly adding pages to some categories. It is supposed to put the following into a page:
<pre>
<noinclude>
<!-- If this page is embedded within another page, noinclude will prevent that page from unintentionally becoming part of these categories -->
[[Category:Stuff]]
[[Category:Some other stuff]]
</noinclude>
</pre>
</noinclude>
Here's a sentence that's not supposed to be transcluded, but will be due to this bug.
<includeonly>
<noinclude>
<!-- If this page is embedded within another page, noinclude will prevent that page from unintentionally becoming part of these categories -->
[[Category:Stuff]]
[[Category:Some other stuff]]
</noinclude>
</includeonly>
Version: 1.16.x
Severity: normal