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

Use keyword paramaters for migration methods for mssql #31309

Merged
merged 1 commit into from
May 16, 2023

Conversation

potiuk
Copy link
Member

@potiuk potiuk commented May 16, 2023

The new alembic (1.11.0) requires parameters to be keyword parameters in methods used in migrations. Part of the problem has been fixed in #31306 and #31302 but still some migrations that are specifically run in case of mssql need to use migration parameters.


^ Add meaningful description above

Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in newsfragments.

@potiuk potiuk added the full tests needed We need to run full set of tests for this PR to merge label May 16, 2023
@potiuk potiuk force-pushed the keyword-parameters-for-mssql-migrations branch from 460c661 to 7287c11 Compare May 16, 2023 07:38
The new alembic (1.11.0) requires parameters to be keyword
parameters in methods used in migrations. Part of the problem has
been fixed in apache#31306 and apache#31302 but still some migrations that are
specifically run in case of mssql need to use migration parameters.
@potiuk potiuk force-pushed the keyword-parameters-for-mssql-migrations branch from 7287c11 to ea1220d Compare May 16, 2023 07:39
Comment on lines +19 to +21
# This file can be modified if you want to make sure the CI build is using "upgrade to newer dependencies"
# Which is useful when you want to check if the dependencies are still compatible with the latest versions
# And they seem to break some unrelated tests in main. You can modify this number = 00001 to trigger it.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
# This file can be modified if you want to make sure the CI build is using "upgrade to newer dependencies"
# Which is useful when you want to check if the dependencies are still compatible with the latest versions
# And they seem to break some unrelated tests in main. You can modify this number = 00001 to trigger it.
# This file can be modified if you want to make sure the CI build is using "upgrade to newer dependencies",
# which is useful when you want to check if the dependencies are still compatible with the latest versions
# as they seem to break some unrelated tests in main. You can modify this number = 00001 to trigger it.

Copy link
Member

Choose a reason for hiding this comment

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

also which number can be modified to 00001 we meant here?

Copy link
Member

Choose a reason for hiding this comment

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

ohh I guess I understood now what was meant here after reading the Slack message. Will it make sense to rephrase this to somewhat like the following?

To make sure the CI build is using "upgrade to newer dependencies", which is useful when you want to check if the dependencies are still compatible with the latest versions as they seem to break some unrelated tests in main, you can modify this file. The modification can be simply modifying this particular comment. e.g. you can modify the following number 00001 to something else to trigger this.

Copy link
Member Author

Choose a reason for hiding this comment

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

Ah. Have not seen the comment> this number (i.e. 00001) can be modified. But if you think you can describe it better - feel free.

Copy link
Member Author

Choose a reason for hiding this comment

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

Basically any change to setup.py will do - even adding a space.

Copy link
Member

Choose a reason for hiding this comment

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

yeah, GitHub is acting weird, my comments are going late. Earlier I tried to merge a couple of PRs and I felt I did but realised now that they were not merged :(

Copy link
Member

Choose a reason for hiding this comment

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

Tried to rephrase it here: #31312

Copy link
Member Author

Choose a reason for hiding this comment

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

I think this time I simply did not refresh the PR. I wanted to merge it fast to fix main so I missed it :)

@potiuk potiuk merged commit 5479027 into apache:main May 16, 2023
@potiuk potiuk deleted the keyword-parameters-for-mssql-migrations branch May 16, 2023 08:33
pankajkoti added a commit to astronomer/airflow that referenced this pull request May 16, 2023
Following up on my late comment in PR apache#31309, this is a try to rephrase
the comment in `setup.py` which indicates how to trigger CI build to use
"upgrade to newer dependencies".
potiuk pushed a commit that referenced this pull request May 16, 2023
Following up on my late comment in PR #31309, this is a try to rephrase
the comment in `setup.py` which indicates how to trigger CI build to use
"upgrade to newer dependencies".
@potiuk potiuk added this to the Airflow 2.6.2 milestone May 16, 2023
@eladkal eladkal added the type:bug-fix Changelog: Bug Fixes label Jun 8, 2023
eladkal pushed a commit that referenced this pull request Jun 8, 2023
Following up on my late comment in PR #31309, this is a try to rephrase
the comment in `setup.py` which indicates how to trigger CI build to use
"upgrade to newer dependencies".

(cherry picked from commit 492acc2)
eladkal pushed a commit that referenced this pull request Jun 8, 2023
The new alembic (1.11.0) requires parameters to be keyword
parameters in methods used in migrations. Part of the problem has
been fixed in #31306 and #31302 but still some migrations that are
specifically run in case of mssql need to use migration parameters.

(cherry picked from commit 5479027)
eladkal pushed a commit that referenced this pull request Jun 9, 2023
Following up on my late comment in PR #31309, this is a try to rephrase
the comment in `setup.py` which indicates how to trigger CI build to use
"upgrade to newer dependencies".

(cherry picked from commit 492acc2)
potiuk added a commit that referenced this pull request Jun 9, 2023
The new alembic (1.11.0) requires parameters to be keyword
parameters in methods used in migrations. Part of the problem has
been fixed in #31306 and #31302 but still some migrations that are
specifically run in case of mssql need to use migration parameters.

(cherry picked from commit 5479027)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
full tests needed We need to run full set of tests for this PR to merge kind:documentation type:bug-fix Changelog: Bug Fixes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants