typing: fix runtime issues

This commit is contained in:
James R. Barlow
2021-08-27 02:18:54 -07:00
parent 3764ee872a
commit cb6c1939e9
2 changed files with 1 additions and 5 deletions
+1 -1
View File
@@ -197,7 +197,7 @@ def rasterize_pdf_page(
@hookspec(firstresult=True)
def filter_ocr_image(page: 'PageContext', image: Image.Image) -> Image.Image:
def filter_ocr_image(page: 'PageContext', image: 'Image.Image') -> 'Image.Image':
"""Called to filter the image before it is sent to OCR.
This is the image that OCR sees, not what the user sees when they view the
-4
View File
@@ -50,10 +50,6 @@ def test_nonmonotonic_warning(caplog):
assert 'out of order' in caplog.text
def test_list_range():
assert _pages_from_ranges([0, 1, 2]) == {0, 1, 2}
def test_limited_pages(resources, outpdf):
multi = resources / 'multipage.pdf'
ocrmypdf.ocr(