cleanup and rename provider to plugin

This commit is contained in:
2026-05-21 16:19:17 -07:00
parent 02d84f423e
commit e8913d1344
62 changed files with 553 additions and 165 deletions
+3 -3
View File
@@ -63,7 +63,7 @@ class _CommandDependencies:
def get_plugin(self, name: str) -> Optional[Any]:
"""Cached plugin lookup by name."""
from ProviderCore.registry import get_plugin
from PluginCore.registry import get_plugin
norm_name = str(name or "").strip().lower()
if not norm_name:
@@ -77,7 +77,7 @@ class _CommandDependencies:
def get_plugin_with_capability(self, name: str, capability: str) -> Optional[Any]:
"""Cached plugin lookup with capability check."""
from ProviderCore.registry import get_plugin_with_capability
from PluginCore.registry import get_plugin_with_capability
norm_name = str(name or "").strip().lower()
if not norm_name:
@@ -2336,7 +2336,7 @@ class Add_File(Cmdlet):
delete_after: bool,
) -> int:
"""Handle uploading via an upload plugin (e.g. 0x0)."""
from ProviderCore.registry import (
from PluginCore.registry import (
get_plugin_with_capability,
list_plugin_names_with_capability,
list_plugins_with_capability,
+1 -1
View File
@@ -13,7 +13,7 @@ from typing import Any, Dict, List, Sequence, Set
from urllib.parse import parse_qs, urlparse
from SYS.logger import log
from ProviderCore.registry import get_plugin
from PluginCore.registry import get_plugin
from SYS.item_accessors import get_http_url, get_sha256_hex, get_store_name
from SYS.utils import extract_hydrus_hash_from_url
+1 -1
View File
@@ -8,7 +8,7 @@ import sys
from pathlib import Path
from SYS.logger import debug, log
from ProviderCore.registry import get_plugin
from PluginCore.registry import get_plugin
from Store import Store
from .. import _shared as sh
from SYS import pipeline as ctx
+2 -2
View File
@@ -992,8 +992,8 @@ class Download_File(Cmdlet):
def _load_provider_registry() -> Dict[str, Any]:
"""Lightweight accessor for plugin helpers without hard dependencies."""
try:
from ProviderCore import registry as provider_registry # type: ignore
from ProviderCore.base import SearchResult # type: ignore
from PluginCore import registry as provider_registry # type: ignore
from PluginCore.base import SearchResult # type: ignore
return {
"get_plugin": getattr(provider_registry, "get_plugin", None),
+1 -1
View File
@@ -154,7 +154,7 @@ def _run(result: Any, args: Sequence[str], config: Dict[str, Any]) -> int:
if urls_to_download and len(urls_to_download) >= 2:
try:
from ProviderCore.registry import get_plugin_for_url
from PluginCore.registry import get_plugin_for_url
expanded: List[Dict[str, Any]] = []
downloaded_any = False
+1 -1
View File
@@ -15,7 +15,7 @@ from urllib.parse import urlparse, parse_qs, unquote, urljoin
from SYS.logger import log, debug, debug_panel
from SYS.payload_builders import build_file_result_payload, normalize_file_extension
from ProviderCore.registry import get_plugin_with_capability, list_plugins_with_capability
from PluginCore.registry import get_plugin_with_capability, list_plugins_with_capability
from SYS.rich_display import (
show_plugin_config_panel,
show_store_config_panel,