Red Hat Bugzilla – Bug 541187
Zero's are being stripped out of code examples included as xi:includes on doc stage
Last modified: 2015-08-09 21:21:56 EDT
Description of problem:
When you push docs to documentation-stage, zeros present in xi:included XML code samples are stripped out.
Version-Release number of selected component (if applicable):
100% on v1.2
Steps to Reproduce:
1. Create a <programlisting> with language="XML" specified as an attribute.
2. In the <programlisting>, xi:include the XML code sample with parse="text" specified as an attribute of the xi:include. (see additional info for an example)
3. Ensure the code sample has zeros present.
3. Publish to any output format and note the lack of zeros present.
The zeros in the XML sample file will be stripped out.
The zeroes should be treated as plain text and left alone.
Through initial troubleshooting locally, it appears that language="XML" attribute is the cause of the problem. Darrin tested includes that use language="Java" and the zeroes remain.
Include as follows:
<programlisting language="XML" role="XML"><xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="extras/pom.xml_sample" parse="text"/></programlisting>
You can check out the JBoss_Documentation_Guide to test this out without creating the include :)
svn co https://svn.devel.redhat.com/repos/ecs/JBoss_Documentation_Guide/
This doesn't happen on RHEL if you bypass the syntax highlighting, and it doesn't happen on fedora rawhide at all.
Will take some digging to determine where the issue is, maybe the Kate highlighting engine or XML::LibXML.
Workaround is to avoid setting the language attribute ... or avoid 0's!
Was a bug in perl-Syntax-Highlight-Engine-Kate, have pushed 0.04-5.el5 from Fedora in to docs repo, will appear in docs repo in the near future.
We don't have a rhel component for that package, so I'm going to close it with notabug since it's not part of this package.
So how would this affect the Documentation-Stage and the fact that it is running RHEL?
Once the perl module is available in the docs repo, will the Docs-Stage also be able to use the updated module? Who would update the Docs-Stage?
(In reply to comment #4)
> So how would this affect the Documentation-Stage and the fact that it is
> running RHEL?
It doesn't affect the docs-stage, it affects books you build locally and in the docs brew root.
> Once the perl module is available in the docs repo, will the Docs-Stage also be
> able to use the updated module? Who would update the Docs-Stage?
The updated package is available in the docs brew root a "short time' after the package has been tagged. Then you need to re-brew the affected books to get them updated.
I mentioned the docs repo because that is where rhel users will get the updated package for local builds of html/pdf etc.