Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding fail-through to Poppler in ImageExtractor to handle a failing PDF with Quartz annotations #126

Closed
wants to merge 2 commits into from

Commits on Feb 5, 2015

  1. adding failing test: pdf annotated with a version of preview.app

      7) Error:
    ExtractImagesTest#test_quartz_annotated:
    Docsplit::ExtractionFailed: Error: /undefinedresult in --run--
    Operand stack:
       --dict:10/10(L)--   0   0   0   0   0   0   0   0   0.0   0.0   0.0   0.0   0.0
    Execution stack:
       %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostringval--   2   %stopped_push   --nostringval--   --nostringval--   --nostringval--   false   1   %stopped_push   1916   1   3   %oparray_pop   1915   1   3   %oparray_pop   1899   1   3   %oparray_pop   --nostringval--   --nostringval--   2   1   1   --nostringval--   %for_pos_int_continue   --nostringval--   --nostringval--   false   1   %stopped_push   --nostringval--   --nostringval--   --nostringval--   %array_continue   --nostringval--   --nostringval--   --nostringval--   --nostringval--   --nostringval--   0   --nostringval--   %repeat_continue   --nostringval--   --nostringval--
    Dictionary stack:
       --dict:1181/1684(ro)(G)--   --dict:1/20(G)--   --dict:83/200(L)--   --dict:83/200(L)--   --dict:113/127(ro)(G)--   --dict:292/300(ro)(G)--   --dict:28/32(L)--   --dict:6/8(L)--   --dict:21/40(L)--
    Current allocation mode is local
    GPL Ghostscript 9.10: Unrecoverable error, exit code 1
    gm convert: "gs" "-q" "-dBATCH" "-dMaxBitmap=50000000" "-dNOPAUSE" "-sDEVICE=pnmraw" "-dTextAlphaBits=4" "-dGraphicsAlphaBits=4" "-r150x150" "-dUseCropBox" "-dFirstPage=1" "-dLastPage=1" "-sOutputFile=/tmp/d20150205-5884-1kbr4v5/gmc1EsXD" "--" "/tmp/d20150205-5884-1kbr4v5/gmnQ9Lfs" "-c" "quit".
    gm convert: Postscript delegate failed (test/fixtures/quartz_annotated.pdf).
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:47:in `block in convert'
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:43:in `each'
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:43:in `convert'
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:19:in `block (3 levels) in extract'
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:19:in `each'
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:19:in `block (2 levels) in extract'
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:18:in `each'
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:18:in `each_with_index'
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:18:in `block in extract'
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:16:in `each'
        /app/vendor/docsplit/lib/docsplit/image_extractor.rb:16:in `extract'
        /app/vendor/docsplit/lib/docsplit.rb:59:in `extract_images'
        /app/vendor/docsplit/test/unit/test_extract_images.rb:33:in `test_quartz_annotated'
    sergeyk committed Feb 5, 2015
    Configuration menu
    Copy the full SHA
    42b7169 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    2aa3cd0 View commit details
    Browse the repository at this point in the history