From cb4d901be3c3c6487c2d53fd0f91b1c6f4861ce1 Mon Sep 17 00:00:00 2001 From: Terrtia Date: Fri, 2 Apr 2021 17:20:03 +0200 Subject: [PATCH] fix: [Indexer] debug messages --- bin/Indexer.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/Indexer.py b/bin/Indexer.py index f86ad7f2..07f06a71 100755 --- a/bin/Indexer.py +++ b/bin/Indexer.py @@ -101,14 +101,14 @@ class Indexer(AbstractModule): PST = Paste.Paste(message) docpath = message.split(" ", -1)[-1] paste = PST.get_p_content() - self.redis_logger.debug("Indexing - " + self.indexname + " :", docpath) + self.redis_logger.debug(f"Indexing - {self.indexname}: {docpath}") # Avoid calculating the index's size at each message if(time.time() - self.last_refresh > self.TIME_WAIT): self.last_refresh = time.time() if self.check_index_size() >= self.INDEX_SIZE_THRESHOLD*(1000*1000): timestamp = int(time.time()) - self.redis_logger.debug("Creating new index", timestamp) + self.redis_logger.debug(f"Creating new index {timestamp}") self.indexpath = join(self.baseindexpath, str(timestamp)) self.indexname = str(timestamp) # update all_index @@ -127,7 +127,7 @@ class Indexer(AbstractModule): indexwriter.commit() except IOError: - self.redis_logger.debug("CRC Checksum Failed on :", PST.p_path) + self.redis_logger.debug(f"CRC Checksum Failed on: {PST.p_path}") self.redis_logger.error('Duplicate;{};{};{};CRC Checksum Failed'.format( PST.p_source, PST.p_date, PST.p_name))