use the right query formatter

This commit is contained in:
Jude Nelson
2018-02-08 19:16:28 -05:00
parent 61b9ec1b93
commit d69734656b

View File

@@ -106,7 +106,7 @@ def db_query_execute(cur, query, values, abort=True, max_timeout=300):
except sqlite3.OperationalError as oe:
if oe.message == "database is locked":
timeout = min(max_timeout, timeout * 2 + timeout * random.random())
log.error("Query timed out due to lock; retrying in %s: %s" % (timeout, namedb_format_query( query, values )))
log.error("Query timed out due to lock; retrying in %s: %s" % (timeout, db_format_query( query, values )))
time.sleep(timeout)
else: