Skip to content

Commit b454fd8

Browse files
committed
fix: Updates for E702 & E231
1 parent d1fd59a commit b454fd8

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

notecard/notecard.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,12 +142,12 @@ def _crc_add(self, req_string, seq_number):
142142
req_bytes = req_string.encode('utf-8')
143143
crc_hex = '{:08x}'.format(crc32(req_bytes))
144144
seq_number_hex = '{:04x}'.format(seq_number)
145-
crc_field = f'"crc":"{seq_number_hex}:{crc_hex}"'
145+
crc_field = f'"crc": "{seq_number_hex}: {crc_hex}"'
146146
req_string_w_crc = req_string[:-1]
147147
if req_string[-2] == '{':
148148
req_string_w_crc += f'{crc_field}'
149149
else:
150-
req_string_w_crc += f',{crc_field}'
150+
req_string_w_crc += f', {crc_field}'
151151
req_string_w_crc += '}'
152152

153153
return req_string_w_crc

test/hitl/example_runner.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,10 @@ def run(self, use_uart, assert_success=True):
1111
pyb = pyboard.Pyboard(self.pyboard_port, 115200)
1212
pyb.enter_raw_repl()
1313
try:
14-
cmd = f'from {self.example_module} import run_example; run_example("{self.product_uid}", {use_uart})'
14+
cmd = (
15+
f'from {self.example_module} import run_example\n'
16+
f'run_example("{self.product_uid}", {use_uart})'
17+
)
1518
output = pyb.exec(cmd)
1619
output = output.decode()
1720
finally:

0 commit comments

Comments
 (0)