-
Notifications
You must be signed in to change notification settings - Fork 21
Description
I wish I could tell you the archiveripper version I'm using, but there's not an option to show the version, right?
I entered the command in powershell "python ripper.py -f pdf" and the script prompted me for my info, but didn't download into a pdf but rather just all the .jpg files, after I left the page # blank, but before, when I entered just "1" without the quotation marks for the number of pages, I got an error:
pages long. Which pages do you want?
Enter a range (eg. 1-15) or leave blank for all: 1
Traceback (most recent call last):
File "C:\software\archiveripper\ripper.py", line 109, in
main()
~~~~^^
File "C:\software\archiveripper\ripper.py", line 72, in main
[start, end] = desired_pages.split('-')
^^^^^^^^^^^^
ValueError: not enough values to unpack (expected 2, got 1)
stupid colour codings in powershell - you can't even see "not enough values to unpack (expected 2, got 1) because it's dark blue text on a dark blue background. And because this github page isn't showing the text in the same font as in powershell, not a font where each letter has the same width as every letter whether i or m, the ^^ should be showing under () after main, and under [start, end]
So when the script had downloaded all the .jpg's, then I got this error:
converting images to pdf
Traceback (most recent call last):
File "C:\Users<myusername modified by me for the sake of this github issue>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\img2pdf.py", line 1891, in read_images
imgdata = Image.open(im)
File "C:\Users<myusername modified by me for the sake of this github issue>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\PIL\Image.py", line 3572, in open
raise UnidentifiedImageError(msg)
PIL.UnidentifiedImageError: cannot identify image file <_io.BytesIO object at 0x000002141A83CFE0>
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\software\archiveripper\ripper.py", line 109, in
main()
~~~~^^
File "C:\software\archiveripper\ripper.py", line 94, in main
pdf_data = img2pdf.convert(img_list)
File "C:\Users<myusername modified by me for the sake of this github issue>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\img2pdf.py", line 2942, in convert
pdf = convert_to_docobject(*images, **kwargs)
File "C:\Users<myusername modified by me for the sake of this github issue>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\img2pdf.py", line 2864, in convert_to_docobject
) in read_images(
~~~~~~~~~~~^
rawdata,
^^^^^^^^
...<3 lines>...
kwargs["include_thumbnails"],
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
):
^
File "C:\Users<myusername modified by me for the sake of this github issue>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\img2pdf.py", line 1947, in read_images
raise ImageOpenError(
...<2 lines>...
)
img2pdf.ImageOpenError: cannot read input image (not jpeg2000). PIL: error reading image: cannot identify image file <_io.BytesIO object at 0x000002141A83CFE0>
again, stupid dark blue text on dark blue background after "img2pdf.ImageOpenError:"
So what I'm asking for, is when the script is asking you all these questions, ask a question like "Convert into pdf? (y/n)"
So I tried again. Command line in powershell:
python ripper.py -f pdf
After finally downloading all the images:
converting images to pdf
Traceback (most recent call last):
File "C:\Users<username>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\img2pdf.py", line 1891, in read_images
imgdata = Image.open(im)
File "C:\Users<username>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\PIL\Image.py", line 3572, in open
raise UnidentifiedImageError(msg)
PIL.UnidentifiedImageError: cannot identify image file <_io.BytesIO object at 0x000001C21F2FA6B0>
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\software\archiveripper\ripper.py", line 109, in
main()
~~~~^^
File "C:\software\archiveripper\ripper.py", line 94, in main
pdf_data = img2pdf.convert(img_list)
File "C:\Users<username>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\img2pdf.py", line 2942, in convert
pdf = convert_to_docobject(*images, **kwargs)
File "C:\Users<username>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\img2pdf.py", line 2864, in convert_to_docobject
) in read_images(
~~~~~~~~~~~^
rawdata,
^^^^^^^^
...<3 lines>...
kwargs["include_thumbnails"],
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
):
^
File "C:\Users<username>\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\img2pdf.py", line 1947, in read_images
raise ImageOpenError(
...<2 lines>...
)
img2pdf.ImageOpenError: cannot read input image (not jpeg2000). PIL: error reading image: cannot identify image file <_io.BytesIO object at 0x000001C21F2FA6B0>
I changed my username in the output here for github to ""