]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
update all errors / warnings in schema to use f strings
authorMike Bayer <mike_mp@zzzcomputing.com>
Sat, 18 Nov 2023 15:22:19 +0000 (10:22 -0500)
committerMike Bayer <mike_mp@zzzcomputing.com>
Sat, 18 Nov 2023 15:24:09 +0000 (10:24 -0500)
commitbc890c9f1042a7ca60b11c53963d329358d3923b
tree164411756c41264dbf3f904a4052ec42eb8c47aa
parentfc80cee2d581699c0a8795f40d9f1bc3d1c03e77
update all errors / warnings in schema to use f strings

Fixed issue where error reporting for unexpected schema item when creating
objects like :class:`_schema.Table` would incorrectly handle an argument
that was itself passed as a tuple, leading to a formatting error.  The
error message has been modernized to use f-strings.

this change necessitated an update to flake8 as version 5 was
mis-interpreting f-strings that had semicolons in them.
Black is also unable to format some of these f-strings which had
to be broken out, unclear if there is a newer Black available.

Fixes: #10654
Change-Id: I703e94282c27ccf06f4aa315e8a11bd97b719170
(cherry picked from commit 2458ceee94e7bd6e5bf8d9d7270be8819bbe772c)
.pre-commit-config.yaml
doc/build/changelog/unreleased_20/10654.rst [new file with mode: 0644]
lib/sqlalchemy/sql/schema.py
test/sql/test_metadata.py