changeset 8403:be227ab4c2e1

perf: lazy evaluate debug logger command.
author John Rouillard <rouilj@ieee.org>
date Sun, 10 Aug 2025 20:31:16 -0400
parents 2af261671cd0
children e7f8b0e1dda1
files roundup/backends/back_anydbm.py
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/roundup/backends/back_anydbm.py	Sun Aug 10 20:23:02 2025 -0400
+++ b/roundup/backends/back_anydbm.py	Sun Aug 10 20:31:16 2025 -0400
@@ -296,7 +296,8 @@
         if not db_type or hasattr(anydbm, 'whichdb'):
             if __debug__:
                 logging.getLogger('roundup.hyperdb.backend').debug(
-                    "opendb anydbm.open(%r, 'c')" % path)
+                    "opendb anydbm.open(%(path)r, 'c')",
+                    {"path": path,})
             return anydbm.open(path, 'c')
 
         # in Python <3 it anydbm was a little dumb so manually open the

Roundup Issue Tracker: http://roundup-tracker.org/