mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-07-30 18:27:45 -05:00
Chore: Convert the consumer to a plugin (#6361)
This commit is contained in:
@@ -67,7 +67,8 @@ class ConsumeTaskPlugin(abc.ABC):
|
||||
self.status_mgr = status_mgr
|
||||
self.task_id: Final = task_id
|
||||
|
||||
@abc.abstractproperty
|
||||
@property
|
||||
@abc.abstractmethod
|
||||
def able_to_run(self) -> bool:
|
||||
"""
|
||||
Return True if the conditions are met for the plugin to run, False otherwise
|
||||
|
@@ -57,7 +57,7 @@ class ProgressManager:
|
||||
message: str,
|
||||
current_progress: int,
|
||||
max_progress: int,
|
||||
extra_args: Optional[dict[str, Union[str, int]]] = None,
|
||||
extra_args: Optional[dict[str, Union[str, int, None]]] = None,
|
||||
) -> None:
|
||||
# Ensure the layer is open
|
||||
self.open()
|
||||
|
Reference in New Issue
Block a user