feat: Add support for the connector pymysql 1.0.2 (#533)

* Document connector-version relationship

* Fix missing option in the command usage documentation

* Rephrase commands descriptions

* Document that pymysql 0.10.0 disabled its warnings

* Disable tests for pymysql newer than 0.10.0 because the behavior changed

* Enable integration tests for pymysql 1.0.2

* Add exclusion to avoid requesting nonexistent test containers

* Cut comments about PyMySQL 1.0.2 need to be fixed

* docs: explain PyMySQL 0.10.0+ returns changed when using IF EXISTS
This commit is contained in:
Laurent Indermühle 2023-05-04 11:14:58 +02:00 committed by GitHub
parent 426084a131
commit 30a2015f6c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 28 additions and 21 deletions

View file

@ -26,9 +26,9 @@ options:
as a formatting character. All literal C(%) characters in the query should be
escaped as C(%%).
- Note that if you use the C(IF EXISTS/IF NOT EXISTS) clauses in your query
and C(mysqlclient) connector, the module will report that
the state has been changed even if it has not. If it is important in your
workflow, use the C(PyMySQL) connector instead.
and C(mysqlclient) or C(PyMySQL 0.10.0+) connectors, the module will report
that the state has been changed even if it has not. If it is important in your
workflow, use the C(PyMySQL 0.9.3) connector instead.
type: raw
required: true
positional_args:
@ -222,7 +222,8 @@ def main():
# When something is run with IF NOT EXISTS
# and there's "already exists" MySQL warning,
# set the flag as True.
# PyMySQL throws the warning, mysqlclinet does NOT.
# PyMySQL < 0.10.0 throws the warning, mysqlclient
# and PyMySQL 0.10.0+ does NOT.
already_exists = True
except Exception as e: