feat: check dir before run_session
This commit is contained in:
5
main.py
5
main.py
@@ -230,10 +230,15 @@ def run_session():
|
|||||||
except Exception as e:
|
except Exception as e:
|
||||||
print(f"Error deleting directory '{DIRNAME}': {e}")
|
print(f"Error deleting directory '{DIRNAME}': {e}")
|
||||||
|
|
||||||
|
def check_dirs():
|
||||||
|
if not os.path.exists(PARSED_DIR):
|
||||||
|
os.mkdir(PARSED_DIR)
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
while True:
|
while True:
|
||||||
try:
|
try:
|
||||||
|
check_dirs()
|
||||||
|
|
||||||
print("BEGIN run_session();")
|
print("BEGIN run_session();")
|
||||||
run_session()
|
run_session()
|
||||||
print("END run_session();")
|
print("END run_session();")
|
||||||
|
|||||||
Reference in New Issue
Block a user