From 26c3e9c327ef07a4562cc0e8c38df09d71abc680 Mon Sep 17 00:00:00 2001 From: Avram Lubkin Date: Tue, 23 May 2023 10:06:43 -0400 Subject: [PATCH] Pylint: Enable consider-using-f-string --- comma/upstream/parser.py | 6 +++--- pylintrc | 3 --- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/comma/upstream/parser.py b/comma/upstream/parser.py index 8493f40..87ff391 100755 --- a/comma/upstream/parser.py +++ b/comma/upstream/parser.py @@ -135,7 +135,7 @@ def process_commits( # The patch commit diffs are stored as "(filename1)\n(diff1)\n(filename2)\n(diff2)..." patch.commitDiffs = "\n".join( [ - "%s\n%s" % (diff.a_path, parse_diff(diff.diff)) + f"{diff.a_path}\n{parse_diff(diff.diff)}" for diff in commit_diffs if diff.a_path is not None ] @@ -159,8 +159,8 @@ def process_commits( num_patches += 1 # Log progress if num_patches % 250 == 0: - logging.debug(" %d commits processed..." % num_patches) + logging.debug(" %d commits processed...", num_patches) if add_to_database: - logging.info("%s patches added to database." % num_patches_added) + logging.info("%s patches added to database.", num_patches_added) return all_patches diff --git a/pylintrc b/pylintrc index e0afd16..af903db 100644 --- a/pylintrc +++ b/pylintrc @@ -27,9 +27,6 @@ disable= # Potential Bugs global-statement, - # Syntax / Logic - consider-using-f-string, - # Logging logging-fstring-interpolation, logging-not-lazy,