Skip to content

Commit

Permalink
fix(trino): bump lower bound to avoid having to handle `experimental_…
Browse files Browse the repository at this point in the history
…python_types`

BREAKING CHANGE: The trino backend now requires at least version 0.321 of the `trino` Python package.
  • Loading branch information
cpcloud authored and kszucs committed May 22, 2023
1 parent 92399b5 commit bf6eeab
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 18 deletions.
20 changes: 4 additions & 16 deletions ibis/backends/trino/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,23 +60,11 @@ def do_connect(
message=r"The dbapi\(\) classmethod on dialect classes has been renamed",
category=sa.exc.SADeprecationWarning,
)
try:
super().do_connect(
sa.create_engine(
url,
connect_args={
**connect_args,
"experimental_python_types": True,
},
poolclass=sa.pool.StaticPool,
)
)
except TypeError:
super().do_connect(
sa.create_engine(
url, connect_args=connect_args, poolclass=sa.pool.StaticPool
)
super().do_connect(
sa.create_engine(
url, connect_args=connect_args, poolclass=sa.pool.StaticPool
)
)

@staticmethod
def _new_sa_metadata():
Expand Down
2 changes: 1 addition & 1 deletion poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ snowflake-connector-python = { version = ">=2.7.10,<4", optional = true }
snowflake-sqlalchemy = { version = ">=1.4.1,<2", optional = true }
sqlalchemy = { version = ">=1.4,<3", optional = true }
sqlalchemy-views = { version = ">=0.3.1,<1", optional = true }
trino = { version = ">=0.319,<1", optional = true, extras = ["sqlalchemy"] }
trino = { version = ">=0.321,<1", optional = true, extras = ["sqlalchemy"] }

[tool.poetry.group.dev.dependencies]
black = ">=22.1.0,<24"
Expand Down

0 comments on commit bf6eeab

Please sign in to comment.