Bug 819420 - Processing instructions should not be stripped during build
Summary: Processing instructions should not be stripped during build
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Publican
Classification: Community
Component: publican
Version: 3.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: 3.0
Assignee: Jeff Fearn 🐞
QA Contact: Ruediger Landmann
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-05-07 07:44 UTC by Raphaël Hertzog
Modified: 2012-10-31 03:11 UTC (History)
2 users (show)

Fixed In Version: 3.0.0
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-10-31 03:11:45 UTC
Embargoed:


Attachments (Terms of Use)

Description Raphaël Hertzog 2012-05-07 07:44:24 UTC
Description: I have put some processing instructions in the XML files (for example <?dbhtml filename="intro.html" ?> or <?latex \pagebreak ?>).

When I build the document, those processing instructions are stripped, i.e. they are no longer present in the tmp/<lang>/xml/* files.

Expected result: The processing instructions should be kept.

Comment 1 Jeff Fearn 🐞 2012-08-17 06:18:27 UTC
Added call to store_pis in XmlClean::process_file.

To ssh://git.fedorahosted.org/git/publican.git
   aa33a03..d608434  master -> master

Comment 2 Andrew Ross 2012-10-03 04:49:21 UTC
Built from upstream source on a RHEL6.3 workstation: publican-3.0-0.el6.t226.noarch

Here's the steps I took to test the fix:

1. Create a new book:

publican create --name Test_Book

2. Insert processessing tags into en-US/Chapter.xml (used both the tags listed in comment #0)

<title>Test Section 1</title>
 <para>
	<?dbhtml filename="intro.html" ?>
	This is a test paragraph in a section <?latex \pagebreak ?>
</para>

3. Build 

publican build --formats html-single --langs en-US

4. Check the tmp/en-US/xml/Chapter.xml in an editor (gedit in my case). Processing commands are still present.

<title>Test Section 1</title>
 <para>
	<?dbhtml filename="intro.html" ?> This is a test paragraph in a section <?latex \pagebreak ?>
</para>


---

During the build I got an unvalidated tag warning [1]. I couldn't find any tags in either en-US or tmp/xml with pi :-/

I removed the 2 processing instruction tags, cleaned and rebuilt. That error didn't appear.

Any ideas if this is PEBKAC or something we should be concerned about?



[1] *WARNING: Unvalidated tag: '~pi'. This tag may not be displayed correctly, may generate invalid xhtml, or may breach Section 508 Accessibility standards.

Comment 3 Jeff Fearn 🐞 2012-10-08 05:05:34 UTC
(In reply to comment #2)
> [1] *WARNING: Unvalidated tag: '~pi'. This tag may not be displayed
> correctly, may generate invalid xhtml, or may breach Section 508
> Accessibility standards.

This is a minor issue and can be ignored. In all likelihood we will be completely removing that warning in the future anyway.


Note You need to log in before you can comment on or make changes to this bug.