Skip to content

Commit

Permalink
prefs: Fix escape code SyntaxWarning during bytecompile.
Browse files Browse the repository at this point in the history
  • Loading branch information
mtwebster committed May 27, 2024
1 parent 6e22eb6 commit 86db98b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/prefs.py
Original file line number Diff line number Diff line change
Expand Up @@ -365,9 +365,9 @@ def __init__(self, main_window, page_name):
stderr=subprocess.DEVNULL
).decode("utf-8")

lshw_out = re.sub("\A\s*{", "[{", lshw_out)
lshw_out = re.sub("}\s*{", "}, {", lshw_out)
lshw_out = re.sub("}\s*\\n\Z", "}]\n", lshw_out)
lshw_out = re.sub(r"\A\s*{", "[{", lshw_out)
lshw_out = re.sub(r"}\s*{", "}, {", lshw_out)
lshw_out = re.sub(r"}\s*\\n\Z", "}]\n", lshw_out)
j = json.loads(lshw_out)
except:
pass
Expand Down

0 comments on commit 86db98b

Please sign in to comment.