From d5f1ff07df5be5332bf6123d9899f9d7953d608c Mon Sep 17 00:00:00 2001 From: nineven Date: Sun, 31 Jan 2021 16:23:02 +0800 Subject: [PATCH] fix cli.py --- fir_ser/api/utils/crontab/run.py | 8 ++++---- fir_ser/cli.py | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/fir_ser/api/utils/crontab/run.py b/fir_ser/api/utils/crontab/run.py index 2c27ba6..7815d7d 100644 --- a/fir_ser/api/utils/crontab/run.py +++ b/fir_ser/api/utils/crontab/run.py @@ -49,10 +49,10 @@ try: auto_delete_tmp_file() - # @register_job(scheduler, "interval", - # seconds=SYNC_CACHE_TO_DATABASE.get("auto_check_ios_developer_active_times")) - # def auto_check_ios_developer_active_job(): - # auto_check_ios_developer_active() + @register_job(scheduler, "interval", + seconds=SYNC_CACHE_TO_DATABASE.get("auto_check_ios_developer_active_times")) + def auto_check_ios_developer_active_job(): + auto_check_ios_developer_active() register_events(scheduler) diff --git a/fir_ser/cli.py b/fir_ser/cli.py index 25976f2..a5354f7 100644 --- a/fir_ser/cli.py +++ b/fir_ser/cli.py @@ -260,4 +260,5 @@ if __name__ == '__main__': app_path = sys.argv[1] if os.path.isfile(app_path): fly_obj.upload_app(app_path) - raise FileNotFoundError(app_path) + else: + raise FileNotFoundError(app_path)