sync
This commit is contained in:
@@ -8,10 +8,13 @@ def execute(conn, path: str) -> dict:
|
|||||||
raise BuzzerError("Keine Antwort auf 'check' empfangen.")
|
raise BuzzerError("Keine Antwort auf 'check' empfangen.")
|
||||||
|
|
||||||
parts = lines[0].split()
|
parts = lines[0].split()
|
||||||
if len(parts) != 2 or parts[0] != "CRC32":
|
if len(parts) != 3 or parts[0] != "CRC32":
|
||||||
raise BuzzerError(f"Unerwartetes Check-Format: {lines[0]}")
|
raise BuzzerError(f"Unerwartetes Check-Format: {lines[0]}")
|
||||||
|
|
||||||
crc32 = int(parts[1], 16)
|
if parts[1] != path:
|
||||||
|
raise BuzzerError(f"Unerwarteter Pfad in Check-Antwort: {parts[1]} (erwartet: {path})")
|
||||||
|
|
||||||
|
crc32 = int(parts[2], 16)
|
||||||
|
|
||||||
return {
|
return {
|
||||||
"crc32": crc32
|
"crc32": crc32
|
||||||
|
|||||||
Reference in New Issue
Block a user