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

remove False from ping() for mysqlclient; need to keep it for pymysql but at the same time watch out for removal #10492

Closed
zzzeek opened this issue Oct 18, 2023 Discussed in #10489 · 2 comments
Labels
bug Something isn't working mysql near-term release addition to the milestone which indicates this should be in a near-term release
Milestone

Comments

@zzzeek
Copy link
Member

zzzeek commented Oct 18, 2023

Discussed in #10489

see thread at PyMySQL/mysqlclient#651 (reply in thread)

we need to remove the False call for mysqlclient immediately, and probably apply introspection to the pymysql version to make sure we are either sending False or we are checking that it no longer accepts an argument.

we should backport and release for 1.4.x also

@zzzeek zzzeek added bug Something isn't working mysql near-term release addition to the milestone which indicates this should be in a near-term release labels Oct 18, 2023
@zzzeek zzzeek added this to the 1.4.x milestone Oct 18, 2023
@sqla-tester
Copy link
Collaborator

Mike Bayer has proposed a fix for this issue in the main branch:

revise argument to mysqlclient/pymysql ping https://gerrit.sqlalchemy.org/c/sqlalchemy/sqlalchemy/+/4926

@sqla-tester
Copy link
Collaborator

Mike Bayer has proposed a fix for this issue in the rel_1_4 branch:

revise argument to mysqlclient/pymysql ping https://gerrit.sqlalchemy.org/c/sqlalchemy/sqlalchemy/+/4928

sqlalchemy-bot pushed a commit that referenced this issue Oct 24, 2023
Repaired a new incompatibility in the MySQL "pre-ping" routine where the
``False`` argument passed to ``connection.ping()``, which is intended to
disable an unwanted "automatic reconnect" feature,  is being deprecated in
MySQL drivers and backends, and is producing warnings for some versions of
MySQL's native client drivers.  It's removed for mysqlclient, whereas for
PyMySQL and drivers based on PyMySQL, the parameter will be deprecated and
removed at some point, so API introspection is used to future proof against
these various stages of removal.

Fixes: #10492
Change-Id: I8a52428c6f93a03b66a605cb0b85cc5924803d6d
references: #10489
(cherry picked from commit 0790c61)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working mysql near-term release addition to the milestone which indicates this should be in a near-term release
Projects
None yet
Development

No branches or pull requests

2 participants