Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: sqlglot dependency needs bumping for 10.0.0 #10817

Closed
1 task done
anjakefala opened this issue Feb 11, 2025 · 1 comment
Closed
1 task done

bug: sqlglot dependency needs bumping for 10.0.0 #10817

anjakefala opened this issue Feb 11, 2025 · 1 comment
Labels
bug Incorrect behavior inside of ibis

Comments

@anjakefala
Copy link
Contributor

anjakefala commented Feb 11, 2025

What happened?

I think this is not a problem anymore on main, because I can't find this code:

File "/home/anja/anaconda3/envs/visidata/lib/python3.11/site-packages/ibis/backends/sql/dialects.py", line 34, in Generator
sge.Median: rename_func("median")

But recording this for posterity.

When I installed ibis-framework[sqlite]==10.0.0 in my local environment, I had these version schemes listed:

Requirement already satisfied: ibis-framework==10.0.0 in /home/anja/anaconda3/envs/visidata/lib/python3.11/site-packages (10.0.0)
Requirement already satisfied: sqlglot<26.4,>=23.4 in /home/anja/anaconda3/envs/visidata/lib/python3.11/site-packages (from ibis-framework==10.0.0) (23.12.2)

However, with sqlglot 23.12.2, I ran into an AttributeError.

This was resolved by bumping sqlglot to 26.

What version of ibis are you using?

10.0.0

What backend(s) are you using, if any?

sqlite

Relevant log output

>>> import ibis
>>> ibis.__version__
'10.0.0'
>>> import ibis.backends.sql.compilers as sc
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/anja/anaconda3/envs/visidata/lib/python3.11/site-packages/ibis/backends/sql/compilers/__init__.py", line 25, in <module>
    from ibis.backends.sql.compilers.athena import AthenaCompiler
  File "/home/anja/anaconda3/envs/visidata/lib/python3.11/site-packages/ibis/backends/sql/compilers/athena.py", line 8, in <module>
    from ibis.backends.sql.compilers.trino import TrinoCompiler
  File "/home/anja/anaconda3/envs/visidata/lib/python3.11/site-packages/ibis/backends/sql/compilers/trino.py", line 23, in <module>
    from ibis.backends.sql.dialects import Trino
  File "/home/anja/anaconda3/envs/visidata/lib/python3.11/site-packages/ibis/backends/sql/dialects.py", line 27, in <module>
    class ClickHouse(_ClickHouse):
  File "/home/anja/anaconda3/envs/visidata/lib/python3.11/site-packages/ibis/backends/sql/dialects.py", line 28, in ClickHouse
    class Generator(_ClickHouse.Generator):
  File "/home/anja/anaconda3/envs/visidata/lib/python3.11/site-packages/ibis/backends/sql/dialects.py", line 34, in Generator
    sge.Median: rename_func("median"),
    ^^^^^^^^^^
AttributeError: module 'sqlglot.expressions' has no attribute 'Median'
>>>

Code of Conduct

  • I agree to follow this project's Code of Conduct
@anjakefala anjakefala added the bug Incorrect behavior inside of ibis label Feb 11, 2025
@cpcloud
Copy link
Member

cpcloud commented Feb 11, 2025

This has already been addressed in dc6b7e0 and will be part of the next bugfix/feature release.

@cpcloud cpcloud closed this as completed Feb 11, 2025
@github-project-automation github-project-automation bot moved this from backlog to done in Ibis planning and roadmap Feb 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Incorrect behavior inside of ibis
Projects
Archived in project
Development

No branches or pull requests

2 participants