diff --git a/src/ocrmypdf/builtin_plugins/concurrency.py b/src/ocrmypdf/builtin_plugins/concurrency.py index d9a072c9..25c6879c 100644 --- a/src/ocrmypdf/builtin_plugins/concurrency.py +++ b/src/ocrmypdf/builtin_plugins/concurrency.py @@ -30,8 +30,6 @@ Queue = Union[multiprocessing.Queue, queue.Queue] UserInit = Callable[[], None] WorkerInit = Callable[[Queue, UserInit, int], None] -RichTqdmProgressAdapter = RichProgressBar # Deprecated shim; remove in OCRmyPDF 16 - def log_listener(q: Queue): """Listen to the worker processes and forward the messages to logging. diff --git a/src/ocrmypdf/optimize.py b/src/ocrmypdf/optimize.py index 004b42d7..f594c244 100644 --- a/src/ocrmypdf/optimize.py +++ b/src/ocrmypdf/optimize.py @@ -71,15 +71,9 @@ def jpg_name(root: Path, xref: Xref) -> Path: def extract_image_filter( - image: Stream, xref: Xref, *args + image: Stream, xref: Xref ) -> tuple[PdfImage, tuple[Name, Object]] | None: """Determine if an image is extractable.""" - if isinstance(image, Pdf): - # Support deprecated old function signature - # TODO Remove for v16 and drop *args from current function signature - image, xref = args[0], args[1] - warn("extract_image_filter: pdf, root parameters ignored", DeprecationWarning) - if image.Subtype != Name.Image: return None if image.Length < 100: