SneaksAndData / adapta

Logging, data connectors, monitoring, secret handling and general lifehacks to make data people lives easier.
Apache License 2.0
8 stars 1 forks source link

[BUG] Unnecessary database dependencies for distributed_object_storage subpackage #458

Closed JanusAsmussen closed 4 months ago

JanusAsmussen commented 4 months ago

Describe the bug The distributed_object_storage subpackage is currently making all database extras (SQLAlchemy, pyodbc, and Snowflake) required dependencies. This issue arises when attempting to import the subpackage without having both the databases and snowflake extras installed, leading to import errors.

The bug seems to arise due to this import statement: https://github.com/SneaksAndData/adapta/blob/279268d379329fe88d2a661a5d7277a69f1c7732/adapta/storage/distributed_object_store/__init__.py#L21

To Reproduce Following command will fail with an import error when databases and snowflake extras are not installed:

from adapta.storage.distributed_object_store.v3.datastax_astra.astra_client import AstraClient

Expected behavior Being able to use the distributed_object_storage subpackage without the databases and snowflake extras.

Python Version: Applicable to all python versions

george-zubrienko commented 4 months ago

@matt035343 could you please take a look