Skip to content

Commit 8cddf63

Browse files
author
Artem
authored
Attempting to fix log file creation exception
1 parent aaceb70 commit 8cddf63

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

main.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -317,6 +317,10 @@ async def main():
317317

318318

319319
if __name__ == "__main__":
320+
try:
321+
os.mkdir(str(PATH_TO_PROGRAM))
322+
except:
323+
pass
320324
logging.basicConfig(level=logging.INFO)
321325
logging.FileHandler(PATH_TO_PROGRAM / "logs.txt")
322326
# logging.StreamHandler() # sys.stderr

0 commit comments

Comments
 (0)