diff mbox series

wic: Standardize on percent-style formatting in exceptions

Message ID 20260702045245.848251-1-gael.portay+rtone@gmail.com
State New
Headers show
Series wic: Standardize on percent-style formatting in exceptions | expand

Commit Message

Gaël PORTAY July 2, 2026, 4:52 a.m. UTC
Switch from lazy formatting with logging arguments (logger.debug("string
%s", var)) to immediate percent operator formatting ("string %s" % var)
for consistency across the codebase.

This ensures unified string formatting style throughout the project.
---
Hello,

I may apply that change to logging as well, but there is much more
occurences ;)

Regards,
Gaël
 src/wic/plugins/source/bootimg_efi.py        | 2 +-
 src/wic/plugins/source/isoimage_isohybrid.py | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/src/wic/plugins/source/bootimg_efi.py b/src/wic/plugins/source/bootimg_efi.py
index fe6c222..7cdd444 100644
--- a/src/wic/plugins/source/bootimg_efi.py
+++ b/src/wic/plugins/source/bootimg_efi.py
@@ -171,7 +171,7 @@  class BootimgEFIPlugin(SourcePlugin):
                              "%s for systemd-boots's boot.conf", configfile)
             else:
                 raise WicError("configfile is specified but failed to "
-                               "get it from %s.", configfile)
+                               "get it from %s." % configfile)
         else:
             # Create systemd-boot configuration using parameters from wks file
             kernel = get_bitbake_var("KERNEL_IMAGETYPE")
diff --git a/src/wic/plugins/source/isoimage_isohybrid.py b/src/wic/plugins/source/isoimage_isohybrid.py
index 0a3ecd3..15dae01 100644
--- a/src/wic/plugins/source/isoimage_isohybrid.py
+++ b/src/wic/plugins/source/isoimage_isohybrid.py
@@ -101,7 +101,7 @@  class IsoImagePlugin(SourcePlugin):
                              configfile)
             else:
                 raise WicError("configfile is specified "
-                               "but failed to get it from %s", configfile)
+                               "but failed to get it from %s" % configfile)
         else:
             splash = os.path.join(target_dir, "splash.jpg")
             if os.path.exists(splash):