Bug 655713 - Publican should not ship PDFs for known broken languages
Summary: Publican should not ship PDFs for known broken languages
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Publican
Classification: Community
Component: publican
Version: 2.3
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: ---
Assignee: Jeff Fearn 🐞
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 654951
TreeView+ depends on / blocked
 
Reported: 2010-11-22 09:14 UTC by Ankit Patel
Modified: 2011-09-06 06:31 UTC (History)
7 users (show)

Fixed In Version: 2.4
Doc Type: Bug Fix
Doc Text:
Known issues are present in the tools that publican uses to render PDF documents. Consequently, rendering PDFs for Indic and right to left languages is broken. To work around the upstream issues, publican no builds PDFs when packaging the following languages: *
Clone Of:
Environment:
Last Closed: 2010-12-08 03:49:17 UTC
Embargoed:


Attachments (Terms of Use)
Add si-LK to the set of Indic languages (to be excluded from pdf generation). (Untested.) (606 bytes, patch)
2011-09-06 06:31 UTC, Peter Moulder
no flags Details | Diff

Description Ankit Patel 2010-11-22 09:14:34 UTC
Description of problem:
With publican and brew combination one can't publish specific formatted documents to docs.redhat.com.

How reproducible:
Everytime

 
Actual results:
With publican+brew one can generate specific formatted document (html, pdf, html-single, etc) locally, but this option is not available in the case of publishing docs to docs.redhat.com

Expected results:
One should be allowed to publish documents in any format of document.

Additional info:
Since Indic localized PDF rendering is not supported at the moment, it has become the high priority to get rid of PDFs generated and published using publican+brew combination.

Comment 2 Jeff Fearn 🐞 2010-11-22 22:26:58 UTC
I'd rephrase this bug to:

Indic PDFs should never be generated for web site packages due to the fonts not being compatible with FOP.

Comment 3 Michael Hideo 2010-11-22 22:40:36 UTC
Changed Product to Fedora.

I think having a switch in the publican.cfg file that allows one to specify individual languages to show pdfs in english would be a wide enough functionality to trap this case and future cases that may arise.

Comment 4 Jeff Fearn 🐞 2010-11-22 23:05:10 UTC
(In reply to comment #3)
> Changed Product to Fedora.
> 
> I think having a switch in the publican.cfg file that allows one to specify
> individual languages to show pdfs in english would be a wide enough
> functionality to trap this case and future cases that may arise.

The untranslated content is not available by the time the PDF is being generated for the web site. It would take quite a bit of re-engineering to carry two XML payloads in the SRPM.

Comment 5 Ruediger Landmann 2010-11-23 03:05:22 UTC
(In reply to comment #2)
> I'd rephrase this bug to:
> 
> Indic PDFs should never be generated for web site packages due to the fonts not
> being compatible with FOP.

There's a related problem for RTL languages (such as ar-SA, fa-IR, he-IL),
since presently, FOP does not support these at all. (Support is expected in FOP
1.1 --
http://www.mail-archive.com/fop-users@xmlgraphics.apache.org/msg15558.html)

If we're going to exclude Indic languages, we should probably exclude these as
well.

Comment 6 Jeff Fearn 🐞 2010-11-23 03:24:14 UTC
Removed PDF from the list of web formats for all Indic + ar-SA, fa-IR, he-IL languages.

Fixed in build: 2.3-0%{?dist}.t47

Comment 7 Ankit Patel 2010-11-23 06:55:42 UTC
(In reply to comment #6)
> Removed PDF from the list of web formats for all Indic + ar-SA, fa-IR, he-IL
> languages.
> 
> Fixed in build: 2.3-0%{?dist}.t47

Thx Jeff, Is there a way I could grab this build and test it?

Couldn't find it on koji neither brew!

Comment 8 Ruediger Landmann 2010-11-23 07:14:41 UTC
(In reply to comment #7)
> (In reply to comment #6)
> > Removed PDF from the list of web formats for all Indic + ar-SA, fa-IR, he-IL
> > languages.
> > 
> > Fixed in build: 2.3-0%{?dist}.t47
> 
> Thx Jeff, Is there a way I could grab this build and test it?

Instructions are here: https://fedorahosted.org/publican/wiki/Installing

If you're using an operating system other than Fedora 13, the dependencies might be somewhat different, but the procedure is otherwise the same. Any error messages that you get while trying to run ./Build local will tell you what dependencies you're missing.

Comment 9 Ankit Patel 2010-11-23 07:36:56 UTC
(In reply to comment #8)
> (In reply to comment #7)
> > (In reply to comment #6)
> > > Removed PDF from the list of web formats for all Indic + ar-SA, fa-IR, he-IL
> > > languages.
> > > 
> > > Fixed in build: 2.3-0%{?dist}.t47
> > 
> > Thx Jeff, Is there a way I could grab this build and test it?
> 
> Instructions are here: https://fedorahosted.org/publican/wiki/Installing
> 
> If you're using an operating system other than Fedora 13, the dependencies
> might be somewhat different, but the procedure is otherwise the same. Any error
> messages that you get while trying to run ./Build local will tell you what
> dependencies you're missing.

Ok, I think better wait for the update from Fedora 13 or Fedora 14, as the bug moved to MODIFIED state.

Comment 10 Misty Stanley-Jones 2010-11-24 05:08:09 UTC
Jeff, I just build a hi-IN PDF in a website. 

publican build --embedtoc --formats=pdf --langs=hi-IN --publish
publican install_book --site_config ./testsite.cfg --lang hi-IN

[mstanley@cheezel testbook]$ pwd
/home/mstanley/testbook/website/hi-IN/Documentation/0.1/pdf/testbook

[mstanley@cheezel testbook]$ rpm -qa |grep publican
publican-2.3-0.fc14.t51.noarch

Comment 11 Ruediger Landmann 2010-11-24 05:50:01 UTC
(In reply to comment #10)
> Jeff, I just build a hi-IN PDF in a website. 

The real test is whether Publican will package the PDF for /shipping/; you can test this by building the package with: 

publican package --binary --lang hi-IN

Take a look in the web RPM and confirm that there's no pdf directory in there

You could also install the package to verify that it installs cleanly, although unless you have a Publican-generated website at the default location (/var/www/html/docs) on your machine, you won't see much when you browse the results.

Comment 12 Misty Stanley-Jones 2010-11-24 05:59:20 UTC
OK, testing the proper thing. When I installed the resultant RPM, no PDF was present in /var/www/html/docs/hi-IN/. Verified.

Comment 13 Ryan Lerch 2010-11-29 00:23:32 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Known issues are present in the tools that publican uses to render PDF documents. Consequently, rendering PDFs for Indic and right to left languages is broken. To work around the upstream issues, publican no builds PDFs when packaging the following languages:
*

Comment 14 Jeff Fearn 🐞 2010-12-08 03:49:17 UTC
Publican 2.4 has shipped with a fix for this issue.

Comment 15 Peter Moulder 2011-09-06 06:29:50 UTC
(I was delaying sending this, but it looks like FOP will still be with us for a while.)

Please add the Indic language si-LK to the list.  From what I can see in the one or two si-LK pdfs I looked at from docs.redhat.org, FOP output for this language suffers both from the font fallback problem (lots of text simply missing) and from poor shaping (resulting in vowel marks disconnected from their consonant).

It looks like publican/lib/publican/Builder.pm is the only file that's affected.  I attach an untested patch.

Comment 16 Peter Moulder 2011-09-06 06:31:54 UTC
Created attachment 521580 [details]
Add si-LK to the set of Indic languages (to be excluded from pdf generation).  (Untested.)


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