Skip to content

Commit 41abaee

Browse files
authored
fix deleting log file even if it doesn't exist
1 parent dfcc398 commit 41abaee

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Sibyl_System/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
import os
1212
import re
1313

14-
15-
os.remove("log.txt")
14+
if os.path.exists('log.txt')
15+
os.remove("log.txt")
1616

1717
logging.basicConfig(
1818
format="%(asctime)s - %(name)s - %(levelname)s - %(message)s",

0 commit comments

Comments
 (0)