Skip to content

Commit

Permalink
Expose _do_sql as part of osc_ingest_tools public interface (#44)
Browse files Browse the repository at this point in the history
* Expose _do_sql as part of osc_ingest_tools public interface

Signed-off-by: Michael Tiemann <[email protected]>

* Update __init__.py

Make isort happy.

Signed-off-by: Michael Tiemann <[email protected]>

* Update trino_utils.py

Make black happy.

Signed-off-by: Michael Tiemann <[email protected]>

* Update setup.py

Bump version number.

Signed-off-by: Michael Tiemann <[email protected]>

---------

Signed-off-by: Michael Tiemann <[email protected]>
  • Loading branch information
MichaelTiemannOSC authored Feb 7, 2023
1 parent eefebad commit 36ab9ae
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion osc_ingest_trino/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
from .dotenv_utils import load_credentials_dotenv
from .sqlcols import enforce_partition_column_order, enforce_sql_column_names, sql_compliant_name
from .sqltypes import create_table_schema_pairs, pandas_type_to_sql
from .trino_utils import TrinoBatchInsert, attach_trino_engine, fast_pandas_ingest_via_hive
from .trino_utils import TrinoBatchInsert, _do_sql, attach_trino_engine, fast_pandas_ingest_via_hive

__all__ = [
"sql_compliant_name",
Expand All @@ -16,4 +16,5 @@
"attach_trino_engine",
"fast_pandas_ingest_via_hive",
"TrinoBatchInsert",
"_do_sql",
]
2 changes: 1 addition & 1 deletion osc_ingest_trino/trino_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"attach_trino_engine",
"fast_pandas_ingest_via_hive",
"TrinoBatchInsert",
"_do_sql",
]


Expand Down Expand Up @@ -70,7 +71,6 @@ def fast_pandas_ingest_via_hive( # noqa: C901
colmap={},
verbose=False,
):

uh8 = uuid.uuid4().hex[:8]
hive_table = f"ingest_temp_{uh8}"

Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

setup(
name="osc-ingest-tools",
version="0.4.2",
version="0.4.3",
description="python tools to assist with standardized data ingestion workflows for the OS-Climate project",
long_description=README,
long_description_content_type="text/markdown",
Expand Down

0 comments on commit 36ab9ae

Please sign in to comment.