Added values to debug logging of DB requests.

This commit is contained in:
Louis Vézina 2019-10-29 11:43:09 -04:00
parent dd41a30ab1
commit 50dfacece0
1 changed files with 3 additions and 3 deletions

View File

@ -93,7 +93,7 @@ class Sqlite3Worker(threading.Thread):
for token, query, values, only_one in iter(self.sql_queue.get, None):
LOGGER.debug("sql_queue: %s", self.sql_queue.qsize())
if token != self.exit_token:
LOGGER.debug("run: %s", query)
LOGGER.debug("run: %s, %s", query, values)
self.run_query(token, query, values, only_one)
execute_count += 1
# Let the executes build up a little before committing to disk
@ -188,9 +188,9 @@ class Sqlite3Worker(threading.Thread):
If it's a select query it will return the results of the query.
"""
if self.exit_set:
LOGGER.debug("Exit set, not running: %s", query)
LOGGER.debug("Exit set, not running: %s, %s", query, values)
return "Exit Called"
LOGGER.debug("execute: %s", query)
LOGGER.debug("execute: %s, %s", query, values)
values = values or []
# A token to track this query with.
token = str(uuid.uuid4())