Menu

#160 PDF file corruption + unresponsive export in Ubuntu Vivid

v1.0_(example)
closed-fixed
nobody
None
5
2018-02-04
2015-08-21
Mélodie
No

Version 0.4.8 in Ubuntu Vivid

Hello,
I meet with two issues: it i's very difficult and long to get the program to react when I want to export to pdf;
I created a pdf from a web page yesterday and put notes on it with Xournal; then saved to .xoj + to a new pdf. For some reasons, it exported to "pdf.pdf.xoj" and to "pdf.pdf". It seems I have exported it twice, because it was so difficult to have it finish the process, that I have probably sent the command twice.

When I rebooted my machine this morning, the full content of the last pdf produced has disappeared, except some notes I had added with blue text. Also I had added several "X" in red and bold in front of the part of the text that I wanted to mark, and they have disappeared too.

But the first export is ok.

My computer is quite in a good shape, all other applications work correctly and are snappy enough, so there must be something peculiar to this version of Xournal, in this version of Ubuntu, which might cause the issue?

Are you planning to update Xournal at some time in the next future?

Best regards,
Mélodie (linuxvillage.org)

Discussion

  • Denis Auroux

    Denis Auroux - 2015-08-21

    Hi, can you e-mail me the whole set of files (the pdf file you
    annotated, the .xoj, .pdf.pdf, .pdf.pdf.xoj ?) (assuming the contents
    are not particularly confidential). My address is auroux @ math berkeley
    edu (with dots instead of spaces of course)

    You write "saved to .xoj + to a new pdf": do you mean you used "File ->
    Save as" and entered a name like something.pdf.pdf ?
    If so, I imagine that the slowdown might have been caused by Ubuntu
    trying to index the contents of that file but getting confused since
    it's not actually a pdf (no matter what filename you indicate, File ->
    Save and File -> Save As always produce a file that is in the .xoj format).

    The normal workflow is File -> Save (or Save as) to produce a .xoj file
    (or .pdf.xoj if you were annotating a pdf file to begin with); and File
    -> Export to PDF to produce a .pdf file (or .pdf.pdf if you started from
    a .pdf file to begin with). Assuming you did exactly this and still it
    was very slow / strange, the next thing is to diagnose what happened.

    Is it File -> Export to PDF that took a long time to complete ? (file
    -> save should normally be fast). If so: was the PDF file you were
    annotating particularly large, or complicated in some way? (export to
    PDF requires reading the contents of the whole PDF file and
    re-processing it to generate a new PDF with the annotations in it). Is
    exporting to PDF slow in all cases, or just when annotating a certain
    PDF file, or files that came from a particular source ?

    There are actually two different "Export to PDF" features in xournal
    0.4.8, so what happens if you instead select Options -> "Legacy PDF
    export" then do File -> Export to PDF ? Does that one work faster /
    better ? (normally, the "new" export is better, though there's a known
    bug affecting it in some cases and then the "legacy" export is better).

    Unfortunately it's not easy to diagnose what happened from the
    description. Seeing the files might or might not help -- I'll try but no
    promises.

    Finally, about new versions: xournal is still evolving, slowly, but I
    try to fix bugs very quickly when I know how to, and I occasionally add
    new features when they're easy / obvious / ... and I have time to spare.
    The version number remains at 0.4.8 for now because the changes since
    last year are still minimal, though there are a few small bugfixes in
    the code base (some of which might or might not have been included in
    the package for Ubuntu vivid). But overall xournal is quite stable by
    now, though with well-known limitations that make some desirable
    features just too hard to add for the time being. So, if we can figure
    out what happened to you and whether it's indeed a bug in xournal
    (rather than Ubuntu's use of unstable versions of some system libraries
    -- I don't know about Vivid but it wouldn't be the first time), we'll
    try to fix it. If the bug is widespread and serious enough to affect a
    number of users then the Ubuntu package can be updated by the maintainer
    if necessary.

    Denis

     
  • Denis Auroux

    Denis Auroux - 2015-10-09

    I now believe the loss of the PDF contents was caused by the user attempting to "export to PDF" to the same file that was being annotated. With the new export-to-pdf, poppler is using the background pdf file's contents during the export process; re-distilling the file to itself was causing data corruption. This should now be fixed in the CVS and GIT repositories. Note that "legacy" PDF export was not affected as it works from a copy in memory.

    Exporting to the same PDF file that you are annotating remains in general a bad idea, as it makes all annotations irreversibly part of the background (+ they stay in the xoj as well) and there is no way to retrieve the original PDF. A strongly worded reminder is now given when the user attempts this.

    Denis

     
  • Denis Auroux

    Denis Auroux - 2015-10-09
    • summary: Issues in Ubuntu Vivid --> PDF file corruption + unresponsive export in Ubuntu Vivid
     
  • Denis Auroux

    Denis Auroux - 2018-02-04
    • status: open --> closed-fixed
     
  • Denis Auroux

    Denis Auroux - 2018-02-04

    The patch added into git and in version 0.4.8.2016 seems to address this satisfactorily.

     

Log in to post a comment.