diff --git a/sqlalchemy-sqlitecloud/sqlalchemy_sqlitecloud/provision.py b/sqlalchemy-sqlitecloud/sqlalchemy_sqlitecloud/provision.py index 28e3001..3bebda7 100644 --- a/sqlalchemy-sqlitecloud/sqlalchemy_sqlitecloud/provision.py +++ b/sqlalchemy-sqlitecloud/sqlalchemy_sqlitecloud/provision.py @@ -1,6 +1,6 @@ import os -from dotenv import load_dotenv +from dotenv import find_dotenv, load_dotenv from sqlalchemy.engine import make_url from sqlalchemy.pool import Pool from sqlalchemy.testing.provision import ( @@ -10,17 +10,13 @@ temp_table_keyword_args, ) -_drivernames = { - "sqlitecloud", -} - @generate_driver_url.for_db("sqlitecloud") def generate_driver_url(url, driver, query_str): # no database specified here, it's created and used later # eg: sqlitecloud://mynode.sqlite.cloud/?apikey=key123 - load_dotenv("../../.env") + load_dotenv(find_dotenv("../../.env")) connection_string = os.getenv("SQLITE_CONNECTION_STRING") apikey = os.getenv("SQLITE_API_KEY") diff --git a/src/sqlitecloud/__init__.py b/src/sqlitecloud/__init__.py index 83da99f..8bd5675 100644 --- a/src/sqlitecloud/__init__.py +++ b/src/sqlitecloud/__init__.py @@ -1,33 +1,7 @@ -# To replicate the public interface of sqlite3, we need to import -# the classes and functions from the dbapi2 module. +# To replicate the public interface of sqlite3, +# we need to import everything from the dbapi2 module. # eg: sqlite3.connect() -> sqlitecloud.connect() # - -from .dbapi2 import ( - PARSE_COLNAMES, - PARSE_DECLTYPES, - Connection, - Cursor, - Row, - adapters, - connect, - converters, - register_adapter, - register_converter, -) - -__all__ = [ - "VERSION", - "Connection", - "Cursor", - "connect", - "register_adapter", - "register_converter", - "PARSE_DECLTYPES", - "PARSE_COLNAMES", - "adapters", - "converters", - "Row", -] +from .dbapi2 import * # noqa VERSION = "0.0.81"