Fix broken tests due to pymysql 1.2.0 incompat with aiomysql#67467
Merged
vatsrahul1001 merged 1 commit intoMay 25, 2026
Merged
Conversation
vatsrahul1001
approved these changes
May 25, 2026
Contributor
Author
|
Lets run with full tests to be sure |
Contributor
Backport failed to create: v3-2-test. View the failure log Run detailsNote: As of Merging PRs targeted for Airflow 3.X In matter of doubt please ask in #release-management Slack channel.
You can attempt to backport this manually by running: cherry_picker 7ea8362 v3-2-testThis should apply the commit to the v3-2-test branch and leave the commit in conflict state marking After you have resolved the conflicts, you can continue the backport process by running: cherry_picker --continueIf you don't have cherry-picker installed, see the installation guide. |
This was referenced May 25, 2026
1 task
vatsrahul1001
added a commit
that referenced
this pull request
May 25, 2026
1 task
vatsrahul1001
added a commit
that referenced
this pull request
May 25, 2026
1 task
potiuk
added a commit
that referenced
this pull request
May 25, 2026
The released apache-airflow-providers-mysql on PyPI does not yet carry the pymysql<1.2 cap from #67467, so PyPI constraint generation picks up pymysql 1.2.0 and breaks SQLAlchemy's AsyncAdapt_aiomysql_connection.ping(). Mirror the cap in the constraints script's additional_constraints_for_highest_resolution so PyPI constraints stay installable until the SQLAlchemy fix is released. Also extend the comment in providers/mysql/pyproject.toml to link the upstream tracking issue (sqlalchemy/sqlalchemy#13306).
potiuk
added a commit
that referenced
this pull request
May 25, 2026
…67492) The released apache-airflow-providers-mysql on PyPI does not yet carry the pymysql<1.2 cap from #67467, so PyPI constraint generation picks up pymysql 1.2.0 and breaks SQLAlchemy's AsyncAdapt_aiomysql_connection.ping(). Mirror the cap in the constraints script's additional_constraints_for_highest_resolution so PyPI constraints stay installable until the SQLAlchemy fix is released. Also extend the comment in providers/mysql/pyproject.toml to link the upstream tracking issue (sqlalchemy/sqlalchemy#13306). (cherry picked from commit 6e9757b) Co-authored-by: Jarek Potiuk <jarek@potiuk.com>
vatsrahul1001
added a commit
that referenced
this pull request
May 25, 2026
vatsrahul1001
pushed a commit
that referenced
this pull request
May 25, 2026
…67492) The released apache-airflow-providers-mysql on PyPI does not yet carry the pymysql<1.2 cap from #67467, so PyPI constraint generation picks up pymysql 1.2.0 and breaks SQLAlchemy's AsyncAdapt_aiomysql_connection.ping(). Mirror the cap in the constraints script's additional_constraints_for_highest_resolution so PyPI constraints stay installable until the SQLAlchemy fix is released. Also extend the comment in providers/mysql/pyproject.toml to link the upstream tracking issue (sqlalchemy/sqlalchemy#13306). (cherry picked from commit 6e9757b) Co-authored-by: Jarek Potiuk <jarek@potiuk.com>
vatsrahul1001
added a commit
that referenced
this pull request
May 25, 2026
vatsrahul1001
pushed a commit
that referenced
this pull request
May 25, 2026
…67492) The released apache-airflow-providers-mysql on PyPI does not yet carry the pymysql<1.2 cap from #67467, so PyPI constraint generation picks up pymysql 1.2.0 and breaks SQLAlchemy's AsyncAdapt_aiomysql_connection.ping(). Mirror the cap in the constraints script's additional_constraints_for_highest_resolution so PyPI constraints stay installable until the SQLAlchemy fix is released. Also extend the comment in providers/mysql/pyproject.toml to link the upstream tracking issue (sqlalchemy/sqlalchemy#13306). (cherry picked from commit 6e9757b) Co-authored-by: Jarek Potiuk <jarek@potiuk.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Was generative AI tooling used to co-author this PR?
Fix for CI like: https://github.com/apache/airflow/actions/runs/26391986239/job/77689459612?pr=67460 and in main too
Current behaviour
pymysql 1.2.0changed the default ofConnection.ping(reconnect)fromTruetoFalse.SQLAlchemy's
_send_false_to_pingmemoized property inspects this signature — when it seesreconnect=Falseit switches to callingdbapi_connection.ping()with no arguments.But SQLAlchemy's
AsyncAdapt_aiomysql_connection.ping(self, reconnect: bool)has no default forreconnect, so the bare call raises aTypeErrorevery time the async connection pool runs apre-ping health check (
pool_pre_ping=True).Error looks like this:
Solution
Cap
pymysql<1.2in the mysql provider's dependencies until SQLAlchemy's aiomysql adapter isupdated to handle the new signature.
{pr_number}.significant.rst, in airflow-core/newsfragments. You can add this file in a follow-up commit after the PR is created so you know the PR number.