From 4310a7459caeb624f21b4d45db220fbac08ec429 Mon Sep 17 00:00:00 2001 From: CHUN YU YAO Date: Sat, 30 Mar 2024 14:44:38 +0800 Subject: [PATCH] 2024-03-17, change version code. --- chrome_tixcraft.py | 10 +++++++--- config_launcher.py | 2 +- kktix_signout.py | 2 +- kktix_status.py | 2 +- settings.py | 2 +- 5 files changed, 11 insertions(+), 7 deletions(-) diff --git a/chrome_tixcraft.py b/chrome_tixcraft.py index b3a9747..a2ecf79 100644 --- a/chrome_tixcraft.py +++ b/chrome_tixcraft.py @@ -45,7 +45,7 @@ except Exception as exc: print(exc) pass -CONST_APP_VERSION = "MaxBot (2024.03.16)" +CONST_APP_VERSION = "MaxBot (2024.03.17)" CONST_MAXBOT_ANSWER_ONLINE_FILE = "MAXBOT_ONLINE_ANSWER.txt" CONST_MAXBOT_CONFIG_FILE = "settings.json" @@ -12629,8 +12629,12 @@ def main(args): driver = None if not config_dict is None: driver = get_driver_by_config(config_dict) - if not config_dict["advanced"]["headless"]: - resize_window(driver, config_dict) + if not driver is None: + if not config_dict["advanced"]["headless"]: + resize_window(driver, config_dict) + else: + print("無法使用web driver,程式無法繼續工作") + sys.exit() else: print("Load config error!") diff --git a/config_launcher.py b/config_launcher.py index bb5cc69..5434845 100644 --- a/config_launcher.py +++ b/config_launcher.py @@ -23,7 +23,7 @@ import sys import threading import webbrowser -CONST_APP_VERSION = "MaxBot (2024.03.16)" +CONST_APP_VERSION = "MaxBot (2024.03.17)" CONST_MAXBOT_LAUNCHER_FILE = "config_launcher.json" CONST_MAXBOT_CONFIG_FILE = "settings.json" diff --git a/kktix_signout.py b/kktix_signout.py index 010c917..30c8aa6 100644 --- a/kktix_signout.py +++ b/kktix_signout.py @@ -11,7 +11,7 @@ import requests import asyncio import nodriver as uc -CONST_APP_VERSION = "MaxBot (2024.03.16)" +CONST_APP_VERSION = "MaxBot (2024.03.17)" CONST_MAXBOT_CONFIG_FILE = "settings.json" USER_AGENT = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/123.0.0.0 Safari/537.36" diff --git a/kktix_status.py b/kktix_status.py index 5c259e5..01e5e91 100644 --- a/kktix_status.py +++ b/kktix_status.py @@ -29,7 +29,7 @@ from datetime import datetime import requests -CONST_APP_VERSION = "MaxBot (2024.03.16)" +CONST_APP_VERSION = "MaxBot (2024.03.17)" CONST_MAXBOT_CONFIG_FILE = "settings.json" CONST_MAXBOT_KKTIX_CONFIG_FILE = "kktix.json" diff --git a/settings.py b/settings.py index cb3fc89..4014757 100644 --- a/settings.py +++ b/settings.py @@ -50,7 +50,7 @@ try: except Exception as exc: pass -CONST_APP_VERSION = "MaxBot (2024.03.16)" +CONST_APP_VERSION = "MaxBot (2024.03.17)" CONST_MAXBOT_ANSWER_ONLINE_FILE = "MAXBOT_ONLINE_ANSWER.txt" CONST_MAXBOT_CONFIG_FILE = "settings.json"