Skip to content

Commit a7aa4e4

Browse files
Copilotdobairoland
andcommitted
Convert remaining .format() calls to f-strings in esp32c2 and esp32h2 field modules
Co-authored-by: dobairoland <[email protected]>
1 parent f279df3 commit a7aa4e4

File tree

2 files changed

+2
-4
lines changed

2 files changed

+2
-4
lines changed

espefuse/efuse/esp32c2/fields.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ def get_coding_scheme_warnings(self, silent=False):
258258
]
259259
block.err_bitarray.pos = 0
260260
for word in reversed(words):
261-
block.err_bitarray.overwrite(BitArray("uint:32={}".format(word)))
261+
block.err_bitarray.overwrite(BitArray(f"uint:32={word}"))
262262
block.num_errors = block.err_bitarray.count(True)
263263
block.fail = block.num_errors != 0
264264
else:

espefuse/efuse/esp32h2/fields.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,7 @@ def __init__(
7272
self.BLOCKS_FOR_KEYS = self.Blocks.get_blocks_for_keys()
7373
if esp.CHIP_NAME != "ESP32-H2":
7474
raise esptool.FatalError(
75-
"Expected the 'esp' param for ESP32-H2 chip but got for '{}'.".format(
76-
esp.CHIP_NAME
77-
)
75+
f"Expected the 'esp' param for ESP32-H2 chip but got for '{esp.CHIP_NAME}'."
7876
)
7977
if not skip_connect:
8078
flags = self._esp.get_security_info()["flags"]

0 commit comments

Comments
 (0)