Bug 1008166 - Printing to a range of a PDF file with acroread to a cups printer prints only the first page of document
Summary: Printing to a range of a PDF file with acroread to a cups printer prints only...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: cups-filters
Version: 19
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Tim Waugh
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 1011965 (view as bug list)
Depends On:
Blocks: 1032117
TreeView+ depends on / blocked
 
Reported: 2013-09-15 11:51 UTC by Joachim Backes
Modified: 2013-12-07 07:04 UTC (History)
4 users (show)

Fixed In Version: cups-filters-1.0.41-4.fc20
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1032117 (view as bug list)
Environment:
Last Closed: 2013-11-24 03:54:39 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
troubleshoot.txt (169.62 KB, text/plain)
2013-09-16 13:27 UTC, Joachim Backes
no flags Details
troubleshoot.txt (335.15 KB, text/plain)
2013-11-18 14:41 UTC, Joachim Backes
no flags Details
d-file from /var/spool/cups (303.91 KB, text/plain)
2013-11-18 15:23 UTC, Joachim Backes
no flags Details

Description Joachim Backes 2013-09-15 11:51:07 UTC
Description of problem:
If opening some PDF file with acroread and printing a page range (previously selected by the acroread printting dialog) will print only the first page of the range. I don't think it is a acroread issue :-)


Version-Release number of selected component (if applicable):

cups-1.6.3-4.fc19.x86_64

How reproducible:
always

Steps to Reproduce:
1. Open a PDF file with acroread
2.Print a page range to a cups printer
3.

Actual results:
 only the first page of the range is printed

Expected results:


Additional info:

0. The same effect if I try to print the whole file
1. If printing the page range to a cups-pdf printer, the range is printed completely

2. printing the same range with "lp -d <printer> -P <page range> <PDF file>" has no flaws!!

Comment 1 Tim Waugh 2013-09-16 12:27:48 UTC
Please run the printing troubleshooter and, when it asks you to print something, do so using acroread (and select a page range).

https://fedoraproject.org/wiki/How_to_debug_printing_problems#Printing_troubleshooter

Comment 2 Joachim Backes 2013-09-16 13:27:20 UTC
Created attachment 798284 [details]
troubleshoot.txt

The printer troubleshooting system says that it can't find any useful information, but it generated troubleshoot.txt which I attached!

Comment 3 Joachim Backes 2013-09-16 13:33:06 UTC
Running no now again the printing troubleshooter, it says:

--------------------------------------------------------------
Status messages:

There are status mesages assiciated with this queue.
The printer's state message is: 'waiting for printer to finish'
--------------------------------------------------------------

But:

$ lpq
ml-1660 is ready
no entries

Comment 4 Tim Waugh 2013-09-25 13:22:29 UTC
*** Bug 1011965 has been marked as a duplicate of this bug. ***

Comment 5 Joachim Backes 2013-09-26 04:54:30 UTC
Still same problems with cups-1.6.4-1.fc19.x86_64

Comment 6 Joachim Backes 2013-10-12 02:49:41 UTC
still same problems with cups-1.6.4-2.fc19.x86_64

Comment 7 Joachim Backes 2013-10-12 02:56:37 UTC
Seeing the same in F20 with cups-1.7-0.26.rc1.fc20.x86_64

Comment 8 Tim Waugh 2013-11-18 13:26:58 UTC
Could you please re-test? This may have been related to bug #1019261. Please note which version of cups-filters you have.

Comment 9 Joachim Backes 2013-11-18 13:49:21 UTC
(In reply to Tim Waugh from comment #8)
> Could you please re-test? This may have been related to bug #1019261. Please
> note which version of cups-filters you have.

Still same problems (only first page of a page range is printed) with AdobeReader_enu-9.5.5-1.i486 and the following cups parts:

cups-pk-helper-0.2.5-2.fc20.x86_64
cups-filters-1.0.41-3.fc20.x86_64
cups-libs-1.7.0-4.fc20.i686
cups-filters-libs-1.0.41-3.fc20.x86_64
cups-libs-1.7.0-4.fc20.x86_64
cups-1.7.0-4.fc20.x86_64
cups-filesystem-1.7.0-4.fc20.noarch
cups-pdf-2.6.1-7.fc20.x86_64

But the problem now disappears if using evince-3.10.2-1.fc20.x86_64 together with the above cups parts: page ranges are printed well and completely:-)

JB

Comment 10 Tim Waugh 2013-11-18 13:58:40 UTC
OK. It's looking like it might be an Adobe bug, as the job in comment #2 does not have the "page-ranges" attribute set. That means Adobe is munging the job itself rather than letting CUPS do it.

To be sure about it, I think we need to capture the actual data that Adobe Reader sends. To do that, run this command as root:

cupsctl PreserveJobFiles=1

Then please run the troubleshooter again and attach the resulting troubleshoot.txt, as well as the /var/spool/cups/d* file you should now have (which is the print job that Adobe Reader submitted).

Comment 11 Joachim Backes 2013-11-18 14:41:52 UTC
Created attachment 825693 [details]
troubleshoot.txt

1. Attached troubleshoot.txt
2. Weird: /var/spool/cups contains no d**** file, only c**** file.

Comment 12 Tim Waugh 2013-11-18 14:55:11 UTC
Oh, there's should have been a file called /var/spool/cups/d00193-001 (193 is the job ID).

Maybe the cupsctl command should be this instead:

cupsctl PreserveJobFiles=Yes

Could you try that?

Comment 13 Joachim Backes 2013-11-18 15:23:06 UTC
Created attachment 825717 [details]
d-file from /var/spool/cups

Seems "cupsctl PreserveJobFiles=1" was the culprit. Exchanging "1" by "Yes" did it!

Comment 14 Tim Waugh 2013-11-18 17:56:47 UTC
So that job (194) has two pages in it. But you only got one out from the printer?

pstops thinks there are two pages. gstoraster thinks there are two pages. I'm starting to think splix is to blame:

'D [16/Sep/2013:15:23:04 +0200] [Job 465] SpliX Page 1 (4779\xc3\x976767 on 4960\xc3\x977017) has been successfully loaded into memory',
'D [16/Sep/2013:15:23:04 +0200] [Job 465] SpliX No more pages',

There's something else wrong too. We should be going via pstotiff but for some reason we are, even with cups-filters-1.0.41-3.fc20 which was meant to contain a fix for this (bug #1019261):

D [18/Nov/2013:15:35:58 +0100] [Job 193] pstops (application/vnd.adobe-reader-postscript to application/vnd.cups-postscript, cost 66)
D [18/Nov/2013:15:35:58 +0100] [Job 193] pstotiff (application/vnd.cups-postscript to image/tiff, cost 80)
D [18/Nov/2013:15:35:58 +0100] [Job 193] imagetoraster (image/tiff to application/vnd.cups-raster, cost 100)
D [18/Nov/2013:15:35:58 +0100] [Job 193] rastertoqpdl (application/vnd.cups-raster to printer/ml-1660, cost 0)

Changing component to cups-filters to focus on this second issue. There may be a splix issue as well.

Comment 15 Joachim Backes 2013-11-18 19:19:44 UTC
(In reply to Tim Waugh from comment #14)
> So that job (194) has two pages in it. But you only got one out from the
> printer?

Right! But why the range is printed well with evince, but not with acroread?

Comment 16 Tim Waugh 2013-11-19 11:43:10 UTC
I expect it's to do with the type of output they produce. evince will produce output identified as application/postscript but acroread's output is identified as application/vnd.adobe-reader-postscript due to this in cupsfilters.types:

# CUPS file detection rule for PostScript which is generated by the Adobe
# Reader. We distinguish PostScript from the Adobe reader here so that we
# can override pstopdf and the PDF workflow for these PostScript files as the
# conversion of them to PDF does not work if the original PDF file was
# encrypted.

application/vnd.adobe-reader-postscript priority(150) contains(0,4096,"%%Creator: Adobe Acrobat") + \
                                (ai eps ps string(0,%!) string(0,<04>%!) \
                                 contains(0,128,<1B>%-12345X) + \
                                 (contains(0,4096,"LANGUAGE=POSTSCRIPT") \
                                  contains(0,4096,"LANGUAGE = Postscript") \
                                  contains(0,4096,"LANGUAGE = PostScript") \
                                  contains(0,4096,"LANGUAGE = POSTSCRIPT") \
                                  (contains(0,4096,<0a>%!) + \
                                   !contains(0,4096,"ENTER LANGUAGE"))))

Comment 17 Tim Waugh 2013-11-19 13:05:04 UTC
I'm building cups-filters-1.0.41-4.fc20 which fixes the filter costs to avoid using pstotiff|imagetoraster. I expect that will fix the problem.

Comment 18 Joachim Backes 2013-11-19 13:44:33 UTC
Tim,

I updated to cups-filters-1.0.41-4.fc20, and this fixed my acroread printing problem: ranges are now printed well.

Thank you very much.

Comment 19 Fedora Update System 2013-11-19 15:33:45 UTC
cups-filters-1.0.41-4.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/FEDORA-2013-21306/cups-filters-1.0.41-4.fc20

Comment 20 Fedora Update System 2013-11-19 15:34:18 UTC
cups-filters-1.0.41-4.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/FEDORA-2013-21409/cups-filters-1.0.41-4.fc19

Comment 21 Fedora Update System 2013-11-19 21:50:03 UTC
Package cups-filters-1.0.41-4.fc20:
* should fix your issue,
* was pushed to the Fedora 20 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing cups-filters-1.0.41-4.fc20'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-21306/cups-filters-1.0.41-4.fc20
then log in and leave karma (feedback).

Comment 22 Fedora Update System 2013-11-24 03:54:39 UTC
cups-filters-1.0.41-4.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 23 Fedora Update System 2013-12-07 07:04:44 UTC
cups-filters-1.0.41-4.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.


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