Hello! I noticed a new-to-me PdfReadWarning warning this afternoon after upgrading PyPDF2 (version 1.27.10):
PdfReadWarning: incorrect startxref pointer(0) [_reader.py:938] (source)
I tested with my own PDFs, and also the files from PDF_Samples in this repo. This warning seems to log on every PDF I attempt to read via:
from PyPDF2 import PdfFileReader
pdf_path = 'some-path/file.pdf'
with open(pdf_path, "rb") as pdf:
pdf_reader = PdfFileReader(pdf)
It looks like the value being returned by _get_xref_issues() is 0, but there's a comment at the top of this method that says a return value of 0 means no issues were found. I haven't noticed any other issues (my script actually still runs just fine!), so I think it's just an over-zealous warning.
Hello! I noticed a new-to-me
PdfReadWarningwarning this afternoon after upgrading PyPDF2 (version 1.27.10):PdfReadWarning: incorrect startxref pointer(0) [_reader.py:938](source)I tested with my own PDFs, and also the files from PDF_Samples in this repo. This warning seems to log on every PDF I attempt to read via:
It looks like the value being returned by
_get_xref_issues()is 0, but there's a comment at the top of this method that says a return value of 0 means no issues were found. I haven't noticed any other issues (my script actually still runs just fine!), so I think it's just an over-zealous warning.