Skip to contentSkip to conversation

scripts/checktransupdate.py: fix missing f prefix in f-string

PATCH In review Haoyang LIU 3 participants 3 messages Aug 11, 2025 – Aug 12, 2025

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 scripts/checktransupdate.py: fix missing f prefix in f-string

add a f prefix for f-string

Fixes 63e96ce050e5 ("scripts: fix all issues reported by pylint")
---
 scripts/checktransupdate.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/checktransupdate.py +1 -1
index e39529e46c3d..b57fb9139f5f 100755
@@ -131,7 +131,7 @@ def check_per_file(file_path):
     opath = get_origin_path(file_path)
 
     if not os.path.isfile(opath):
-        logging.error("Cannot find the origin path for {file_path}")
+        logging.error(f"Cannot find the origin path for {file_path}")
         return
 
     o_from_head = get_latest_commit_from(opath, "HEAD")
Signature · 1 line
2.50.1
#1 lore raw
Quoted 13 lines · Haoyang LIU

add a f prefix for f-string

Fixes 63e96ce050e5 ("scripts: fix all issues reported by pylint")
---
 scripts/checktransupdate.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/checktransupdate.py +0 -0
index e39529e46c3d..b57fb9139f5f 100755

scripts/checktransupdate.py def check_per_file(file_path): · line 135

Quoted 6 lines
scripts/checktransupdate.py +1 -1
@@ -131,7 +131,7 @@ def check_per_file(file_path):
     opath = get_origin_path(file_path)
 
     if not os.path.isfile(opath):
-        logging.error("Cannot find the origin path for {file_path}")
+        logging.error(f"Cannot find the origin path for {file_path}")
         return

Ouch, good catch; I've applied this.

Thanks,

jon

#2 lore raw
Quoted 17 lines · Jonathan Corbet
Quoted 15 lines · Haoyang LIU

add a f prefix for f-string

Fixes 63e96ce050e5 ("scripts: fix all issues reported by pylint")
---
  scripts/checktransupdate.py | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
scripts/checktransupdate.py +0 -0
index e39529e46c3d..b57fb9139f5f 100755
@@ -131,7 +131,7 @@ def check_per_file(file_path):
      opath = get_origin_path(file_path)
 
Quoted 5 lines

scripts/checktransupdate.py def check_per_file(file_path): · line 135

Quoted 4 lines
scripts/checktransupdate.py +1 -1
      if not os.path.isfile(opath):
-        logging.error("Cannot find the origin path for {file_path}")
+        logging.error(f"Cannot find the origin path for {file_path}")
          return

Ouch, good catch; I've applied this.

Wonder why pylint cannot catch this issue.

The Fixes tag is my commit - "fix all issues reported by pylint", :\

Dongliang Mu

Quoted 4 lines

Thanks,

jon