Skip to content

issue 1166 Update test to use SQLAlchemy 2.0 compatible select statement #1167

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

Merged
merged 9 commits into from
Mar 13, 2025
2 changes: 2 additions & 0 deletions pandas-stubs/io/sql.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ from pandas.core.frame import DataFrame
import sqlalchemy.engine
from sqlalchemy.orm import FromStatement
import sqlalchemy.sql.expression
from sqlalchemy.sql.expression import UpdateBase
from typing_extensions import TypeAlias

from pandas._libs.lib import NoDefault
Expand All @@ -33,6 +34,7 @@ _SQLStatement: TypeAlias = (
| sqlalchemy.sql.expression.TextClause
| sqlalchemy.sql.Select
| FromStatement
| UpdateBase
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of importing UpdateBase, use the pattern as in lines 33 and 34, and place sqlalchemy.sql.expression.UpdateBase here

)

@overload
Expand Down