Skip to content

Instantly share code, notes, and snippets.

@titimoby
Created January 10, 2020 09:31
Show Gist options
  • Save titimoby/383dfca890d611d94b1b6835bf38a8a2 to your computer and use it in GitHub Desktop.
Save titimoby/383dfca890d611d94b1b6835bf38a8a2 to your computer and use it in GitHub Desktop.
import pdftotext
with open("data/2020 01 02.pdf") as f:
... pdf = pdftotext.PDF(f)
...
Traceback (most recent call last):
File "<input>", line 2, in <module>
File "/usr/lib/python3.7/codecs.py", line 322, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe2 in position 10: invalid continuation byte
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment