Skip to content

all: Enable Ruff lint F541 'f-string without any placeholders'. #857

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions micropython/espflash/espflash.py
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ def flash_read_size(self):

def flash_attach(self):
self._command(_CMD_SPI_ATTACH, struct.pack("<II", 0, 0))
print(f"Flash attached")
print("Flash attached")

def flash_config(self, flash_size=2 * 1024 * 1024):
self._command(
Expand Down Expand Up @@ -288,7 +288,7 @@ def flash_write_file(self, path, blksize=0x1000):
def flash_verify_file(self, path, digest=None, offset=0):
if digest is None:
if self.md5sum is None:
raise Exception(f"MD5 checksum missing.")
raise Exception("MD5 checksum missing.")
digest = binascii.hexlify(self.md5sum.digest())

size = os.stat(path)[6]
Expand All @@ -300,7 +300,7 @@ def flash_verify_file(self, path, digest=None, offset=0):
if digest == data[0:32]:
print("Firmware verified.")
else:
raise Exception(f"Firmware verification failed.")
raise Exception("Firmware verification failed.")

def reboot(self):
payload = struct.pack("<I", 0)
Expand Down
2 changes: 1 addition & 1 deletion micropython/lora/lora-async/lora/async_modem.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ async def _wait(self, will_irq, idx, timeout_ms):
await asyncio.sleep_ms(timeout_ms)

if _DEBUG:
print(f"wait complete")
print("wait complete")

def _callback(self):
# IRQ callback from BaseModem._radio_isr. May be in Hard IRQ context.
Expand Down
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ ignore = [
"F403",
"F405",
"E501",
"F541",
"ISC001",
"ISC003", # micropython does not support implicit concatenation of f-strings
"PIE810", # micropython does not support passing tuples to .startswith or .endswith
Expand Down
Loading