-
Notifications
You must be signed in to change notification settings - Fork 28
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
fix: ALTER COLUMN NOT NULL directive fails because of inappropriate syntax #124
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -60,6 +60,12 @@ class = StreamHandler | |
sa.Column('id', sa.Integer, primary_key=True), | ||
sa.Column('name', sa.String(50), nullable=False), | ||
sa.Column('description', sa.Unicode(200)), | ||
) | ||
op.alter_column( | ||
'account', | ||
'name', | ||
existing_type=sa.String(50), | ||
nullable=True, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Adding the issue case into the migration test (the original error could be repeated this way before these changes) |
||
)""" | ||
|
||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,7 +19,11 @@ | |
|
||
name = "sqlalchemy-spanner" | ||
description = "SQLAlchemy dialect integrated into Cloud Spanner database" | ||
dependencies = ["sqlalchemy>=1.1.13, <=1.3.23", "google-cloud-spanner>=3.3.0"] | ||
dependencies = [ | ||
"sqlalchemy>=1.1.13, <=1.3.23", | ||
"google-cloud-spanner>=3.3.0", | ||
"alembic", | ||
] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. As we're now describing some alembic overrides, it should be mentioned in dependencies |
||
extras = { | ||
"tracing": [ | ||
"opentelemetry-api >= 1.1.0", | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are two syntax diverges:
Spanner supports
NULL/NOT NULL
statement without theDROP
word in front of it for constraints droppingSpanner doesn't use
TYPE
word for column type mentionsThese two overrides covers both items.