Files
seedPass/src/nostr/__init__.py
2025-07-02 15:49:02 -04:00

32 lines
620 B
Python

# nostr/__init__.py
"""Nostr package exposing :class:`NostrClient` lazily."""
from importlib import import_module
import logging
from .backup_models import (
KIND_MANIFEST,
KIND_SNAPSHOT_CHUNK,
KIND_DELTA,
Manifest,
ChunkMeta,
)
logger = logging.getLogger(__name__)
__all__ = [
"NostrClient",
"KIND_MANIFEST",
"KIND_SNAPSHOT_CHUNK",
"KIND_DELTA",
"Manifest",
"ChunkMeta",
]
def __getattr__(name: str):
if name == "NostrClient":
return import_module(".client", __name__).NostrClient
raise AttributeError(f"module '{__name__}' has no attribute '{name}'")