polyfile icon indicating copy to clipboard operation
polyfile copied to clipboard

UnboundLocalError: local variable 'is_dct_decode' referenced before assignment

Open tballison opened this issue 5 years ago • 1 comments

[Traceback (most recent call last):, File "/usr/local/bin/polyfile", line 11, in <module>, load_entry_point('polyfile', 'console_scripts', 'polyfile')(), File "/Users/allison/Documents/tob/polyfile/__main__.py", line 72, in main, for match in matcher.match(file_path, progress_callback=progress_callback):, File "/Users/allison/Documents/tob/polyfile/polyfile.py", line 170, in match, yield from submatch_iter, File "/Users/allison/Documents/tob/polyfile/pdf.py", line 288, in submatch, yield from parse_pdf(file_stream, matcher=self.matcher, parent=self), File "/Users/allison/Documents/tob/polyfile/pdf.py", line 282, in parse_pdf, yield from parse_object(file_stream, object, matcher=matcher, parent=parent), File "/Users/allison/Documents/tob/polyfile/pdf.py", line 208, in parse_object, if is_dct_decode and raw_content[:1] == b'\xff':, UnboundLocalError: local variable 'is_dct_decode' referenced before assignment

triggering file: common_crawl/6fb/9cc/eb3/6fb9cceb33a2bf98749e895e43840e90f4bcbf4a631b512c010675e3763f5433

tballison avatar Nov 20 '19 19:11 tballison