Skip to content

Commit

Permalink
Processor.download: apply config.OCRD_DOWNLOAD_INPUT no sooner than a…
Browse files Browse the repository at this point in the history
…vailable, remove useless download_files kwarg
  • Loading branch information
bertsky committed Feb 22, 2025
1 parent 62cf25c commit d30a673
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/ocrd/processor/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,6 @@ def __init__(
input_file_grp=None,
output_file_grp=None,
page_id=None,
download_files=config.OCRD_DOWNLOAD_INPUT,
version=None
):
"""
Expand All @@ -331,8 +330,6 @@ def __init__(
(or empty for all pages). \
Deprecated since version 3.0: Should be ``None`` here, but then needs to be set \
before processing.
download_files (boolean): Whether input files will be downloaded prior to processing, \
defaults to :py:attr:`ocrd_utils.config.OCRD_DOWNLOAD_INPUT` which is ``True`` by default
"""
if ocrd_tool is not None:
deprecation_warning("Passing 'ocrd_tool' as keyword argument to Processor is deprecated - "
Expand Down Expand Up @@ -361,7 +358,7 @@ def __init__(
deprecation_warning("Passing a page_id kwarg other than 'None' to Processor "
"is deprecated - pass as argument to process_workspace instead")
self.page_id = page_id or None
self.download = download_files
self.download = config.OCRD_DOWNLOAD_INPUT
#: The logger to be used by processor implementations.
# `ocrd.processor.base` internals should use :py:attr:`self._base_logger`
self.logger = getLogger(f'ocrd.processor.{self.__class__.__name__}')
Expand Down

0 comments on commit d30a673

Please sign in to comment.