Nightly: refactor readability, progress callbacks, and resource handling
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from abc import ABC, abstractmethod
|
||||
from typing import Any, Dict, List, Optional, Set, Tuple
|
||||
from typing import Any, Callable, Dict, List, Optional, Set, Tuple
|
||||
|
||||
|
||||
class BasisPlugin(ABC):
|
||||
@@ -15,7 +15,11 @@ class BasisPlugin(ABC):
|
||||
prefer_source_metadata: bool = False
|
||||
|
||||
@abstractmethod
|
||||
async def search_titles(self, query: str) -> List[str]:
|
||||
async def search_titles(
|
||||
self,
|
||||
query: str,
|
||||
progress_callback: Optional[Callable[[str, Optional[int]], Any]] = None,
|
||||
) -> List[str]:
|
||||
"""Liefert eine Liste aller Treffer fuer die Suche."""
|
||||
|
||||
@abstractmethod
|
||||
|
||||
Reference in New Issue
Block a user