bugfix: #128 Delete special charactors at filename

This commit is contained in:
voidking 2023-08-07 17:00:30 +08:00
parent 0601ad9c76
commit 7fc5dd9da2

View file

@ -93,6 +93,7 @@ class Engineer(Role):
def write_file(self, filename: str, code: str):
workspace = self.get_workspace()
filename = filename.replace('"', '').replace('\n', '')
file = workspace / filename
file.parent.mkdir(parents=True, exist_ok=True)
file.write_text(code)