refactor: rename _supervise_types → supervise_types (treat as public)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit was merged in pull request #329.
This commit is contained in:
@@ -6,11 +6,11 @@ import sqlite3
|
||||
from pathlib import Path
|
||||
|
||||
try:
|
||||
from ._supervise_types import AuditEntry, host_db_path
|
||||
from .supervise_types import AuditEntry, host_db_path
|
||||
from .db_store import DbStore
|
||||
from .migrations import TableMigrations
|
||||
except ImportError:
|
||||
from _supervise_types import AuditEntry, host_db_path # type: ignore[import-not-found] # pylint: disable=import-error,no-name-in-module
|
||||
from supervise_types import AuditEntry, host_db_path # type: ignore[import-not-found] # pylint: disable=import-error,no-name-in-module
|
||||
from db_store import DbStore # type: ignore[import-not-found] # pylint: disable=import-error,no-name-in-module
|
||||
from migrations import TableMigrations # type: ignore[import-not-found] # pylint: disable=import-error,no-name-in-module
|
||||
|
||||
|
||||
@@ -7,11 +7,11 @@ import sqlite3
|
||||
from pathlib import Path
|
||||
|
||||
try:
|
||||
from ._supervise_types import Proposal, Response, host_db_path
|
||||
from .supervise_types import Proposal, Response, host_db_path
|
||||
from .db_store import DbStore
|
||||
from .migrations import TableMigrations
|
||||
except ImportError:
|
||||
from _supervise_types import Proposal, Response, host_db_path # type: ignore[import-not-found] # pylint: disable=import-error,no-name-in-module
|
||||
from supervise_types import Proposal, Response, host_db_path # type: ignore[import-not-found] # pylint: disable=import-error,no-name-in-module
|
||||
from db_store import DbStore # type: ignore[import-not-found] # pylint: disable=import-error,no-name-in-module
|
||||
from migrations import TableMigrations # type: ignore[import-not-found] # pylint: disable=import-error,no-name-in-module
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ from dataclasses import dataclass
|
||||
from pathlib import Path
|
||||
|
||||
try:
|
||||
from ._supervise_types import (
|
||||
from .supervise_types import (
|
||||
ACTION_OPERATOR_EDIT,
|
||||
AuditEntry,
|
||||
HOST_DB_FILENAME,
|
||||
@@ -57,7 +57,7 @@ try:
|
||||
bot_bottle_root,
|
||||
)
|
||||
except ImportError:
|
||||
from _supervise_types import ( # type: ignore[import-not-found,no-redef] # pylint: disable=import-error,no-name-in-module
|
||||
from supervise_types import ( # type: ignore[import-not-found,no-redef] # pylint: disable=import-error,no-name-in-module
|
||||
ACTION_OPERATOR_EDIT,
|
||||
AuditEntry,
|
||||
HOST_DB_FILENAME,
|
||||
|
||||
@@ -49,7 +49,7 @@ def bot_bottle_root() -> Path:
|
||||
|
||||
def host_db_path() -> Path:
|
||||
# Look up bot_bottle_root through this module's live namespace so that
|
||||
# monkey-patches on _supervise_types.bot_bottle_root take effect.
|
||||
# monkey-patches on supervise_types.bot_bottle_root take effect.
|
||||
return sys.modules[__name__].bot_bottle_root() / HOST_DB_FILENAME
|
||||
|
||||
|
||||
Reference in New Issue
Block a user