]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
Use tuple instead of raw url in string formatting (#7987)
authordzcode <9089037+dzcode@users.noreply.github.com>
Tue, 3 May 2022 20:18:43 +0000 (14:18 -0600)
committerGitHub <noreply@github.com>
Tue, 3 May 2022 20:18:43 +0000 (22:18 +0200)
* Fixes: #7902 - Use tuple instead of raw url in string formatting

* Fix lint error

lib/sqlalchemy/testing/provision.py

index d7f7958060791f553b17166178ba70ede68b74e8..d384377324960438b825d9e95d208ffe5191228a 100644 (file)
@@ -290,13 +290,15 @@ def create_db(cfg, eng, ident):
     Used when a test run will employ multiple processes, e.g., when run
     via `tox` or `pytest -n4`.
     """
-    raise NotImplementedError("no DB creation routine for cfg: %s" % eng.url)
+    raise NotImplementedError(
+        "no DB creation routine for cfg: %s" % (eng.url,)
+    )
 
 
 @register.init
 def drop_db(cfg, eng, ident):
     """Drop a database that we dynamically created for testing."""
-    raise NotImplementedError("no DB drop routine for cfg: %s" % eng.url)
+    raise NotImplementedError("no DB drop routine for cfg: %s" % (eng.url,))
 
 
 @register.init
@@ -380,7 +382,7 @@ def temp_table_keyword_args(cfg, eng):
     ComponentReflectionTest class in suite/test_reflection.py
     """
     raise NotImplementedError(
-        "no temp table keyword args routine for cfg: %s" % eng.url
+        "no temp table keyword args routine for cfg: %s" % (eng.url,)
     )