#995216 simple-scan: B&W Text scans saved as gibberish

Package:
simple-scan
Source:
simple-scan
Description:
Simple Scanning Utility
Submitter:
Felix Lechner
Date:
2021-10-01 11:48:04 UTC
Severity:
normal
Tags:
#995216#5
Date:
2021-09-28 00:37:55 UTC
From:
To:
Hi,

Starting earlier today (between scans) simple-scan on bullseye became
unable to save B&W text scans properly. Now they are saved as
gibberish.

It is possible the files are being saved in a format not understood by
my PDF reader, but I could not find a common reader that worked: I
tried evince, muPDF, gscan2pdf, an old trial version of Master PDF
Editor, and GIMP and Inkscape. Only LibreOffice Draw got it right.

In accordance with the recommendations here [1] I marked the bug
'grave' because I lost data because of it (or so it seemed when I
wrote). The bug is also somewhat treacherous: The image on the screen
looks fine. One has to open the saved file to see the issue.

Thanks for simple-scan! It's a great and best-in-class program!

Kind regards
Felix Lechner

[1] https://www.debian.org/Bugs/Developer#severities

#995216#10
Date:
2021-09-28 01:43:16 UTC
From:
To:
Here is a test scan of a small flyer about EFTPS from the US
Department of the Treasury. Unfortunately, I could not find it online.

The second file is a reduced quality screenshot showing the transition
between both pages in evince on my system. The second page looks okay.

The scanner is a Fujitsu ScanSnap S510, but as noted earlier the image
looks fine on the screen in simple-scan.

Thanks for looking into it!

#995216#15
Date:
2021-09-28 09:49:46 UTC
From:
To:
severity 995216 normal
tags 995216 + moreinfo
thanks


Hello Felix,

thank you for spending your time helping to make Debian better with
this bug report.

First of all, I set the severity to normal, because there is no data
loss in the sense of grave, but only an erroneous output.

For a better understanding please answer the following questions:
 - What was the occupancy of the mouted partitions?
 - How big was the logfile (~/.cache/simple-scan/simple-scan.log)?
 - What was recorded in the logfile at the time of the error?
 - Does the error still occur after a reboot?

And so that I have all system information can you please start once:

  bugreport -N 995216


CU
Jörg


Am Montag, dem 27.09.2021 um 17:37 -0700 schrieb Felix Lechner:

#995216#24
Date:
2021-10-01 05:39:41 UTC
From:
To:

#995216#29
Date:
2021-10-01 05:53:50 UTC
From:
To:
Hi,

Well, I am trying to read over a month's worth of scanned personal and
business documents. I may have lost access to the data—except for LO
Draw, apparently—due to this bug. Maybe it's not a bug in simple-scan,
but something mangled the image data. The hard copies are shredded.

Other users may also have issues and not realize it, either.

Here is an overview of my mounted partitions:

Filesystem                                 Size  Used Avail Use% Mounted on
udev                                        13G     0   13G   0% /dev
tmpfs                                      2.6G  1.8M  2.6G   1% /run
/dev/mapper/optivg-stable                   41G   27G   12G  70% /
tmpfs                                       13G   92M   13G   1% /dev/shm
tmpfs                                      5.0M  4.0K  5.0M   1% /run/lock
/dev/mapper/optivg-nodeb                   4.8G  4.2G  405M  92% /nodeb
/dev/mapper/optivg-fscache                 4.9G  4.2G  480M  90%
/var/cache/fscache
/dev/mapper/optivg-home.local               25G   14G  9.8G  59% /lcl
/dev/sda127                                500M  5.2M  494M   2% /boot/efi
/dev/mapper/optivg-tmp                     197G   62M  188G   1% /tmp
/dev/mapper/optivg-schroot.unstable.amd64  4.9G  1.3G  3.4G  27%
/var/lib/schroot/union/underlay/unstable-amd64-e469dd9d-9737-4e57-96e7-fe321d53cc2f
unstable-amd64                              41G   27G   12G  70%
/run/schroot/mount/unstable-amd64-e469dd9d-9737-4e57-96e7-fe321d53cc2f
tmpfs                                       13G     0   13G   0%
/run/schroot/mount/unstable-amd64-e469dd9d-9737-4e57-96e7-fe321d53cc2f/dev/shm
wallace-server:/mirror                     1.5T  618G  828G  43% /mirror
wallace-server:/acct                       1.5T  1.3T  266G  83% /acct
tmpfs                                      2.6G   68K  2.6G   1% /run/user/0
tmpfs                                      2.6G   28M  2.6G   2% /run/user/1000

For another scan job that was likewise garbled (my son's homework) the
size was about 2 MB.

I believe reportbug forwarded a copy but a compressed version, which
is much smaller, is also attached to this message.

Yes, after each of at least two reboots.

Meanwhile I also installed simple-scan and Evince from unstable on my
otherwise bullseye machine (with backports) but the symptoms are the
same. Perhaps it is worthwhile to point out that I am using Sway, and
not Gnome.

You probably meant reportbug. I do not use it much but it worked very
well, especially with the custom data collection.

I use your tool almost every day. Thanks for looking into this issue!

Kind regards
Felix Lechner

#995216#34
Date:
2021-10-01 11:44:08 UTC
From:
To:
Hi,

I believe the corruption is caused by the page cleanup. Dirty pages
are affected more often, while legible and corrupted pages appear
together in the same documents. Thanks!

Kind regards
Felix Lechner