import importlib.metadata
import sys

from .sqlite import Connection as Connection
from .sqlite import Cursor as Cursor
from .sqlite import connect as connect
from .sqlite import disable_cancellation as disable_cancellation
from .sqlite import enable_cancellation as enable_cancellation
from .sqlite import exception_logger as exception_logger


__version__ = importlib.metadata.version("sqlite_anyio")

if sys.platform == "emscripten":
    disable_cancellation()  # pragma: nocover
