diff --git a/client/config.ini b/client/config.ini index 292a76ee0..d05d5a6a5 100644 --- a/client/config.ini +++ b/client/config.ini @@ -31,7 +31,7 @@ USERNAME= PASSWORD= [LICENSE_CONFIG] -; [可选]使用自研工具时,需要填写,默认不需要 +; [可选]使用自研工具时,需要填写,默认不需要(优先企业或高校申请License) ; license服务器url, base_path, license URL= BASE_PATH= diff --git a/client/task/authcheck/check_license.cp37-win_amd64.pyd b/client/task/authcheck/check_license.cp37-win_amd64.pyd index 60e4e0b05..af0ec04ca 100755 Binary files a/client/task/authcheck/check_license.cp37-win_amd64.pyd and b/client/task/authcheck/check_license.cp37-win_amd64.pyd differ diff --git a/client/task/authcheck/check_license.cpython-37m-aarch64-linux-gnu.so b/client/task/authcheck/check_license.cpython-37m-aarch64-linux-gnu.so index 416925877..a59763e92 100755 Binary files a/client/task/authcheck/check_license.cpython-37m-aarch64-linux-gnu.so and b/client/task/authcheck/check_license.cpython-37m-aarch64-linux-gnu.so differ diff --git a/client/task/authcheck/check_license.cpython-37m-darwin.so b/client/task/authcheck/check_license.cpython-37m-darwin.so index 8d41b3147..2bf254b02 100755 Binary files a/client/task/authcheck/check_license.cpython-37m-darwin.so and b/client/task/authcheck/check_license.cpython-37m-darwin.so differ diff --git a/client/task/authcheck/check_license.cpython-37m-x86_64-linux-gnu.so b/client/task/authcheck/check_license.cpython-37m-x86_64-linux-gnu.so index c71aa7628..761da539d 100755 Binary files a/client/task/authcheck/check_license.cpython-37m-x86_64-linux-gnu.so and b/client/task/authcheck/check_license.cpython-37m-x86_64-linux-gnu.so differ diff --git a/client/util/api/httpclient.py b/client/util/api/httpclient.py index f2cfd0ac9..e2334afdb 100644 --- a/client/util/api/httpclient.py +++ b/client/util/api/httpclient.py @@ -8,6 +8,7 @@ """ http client """ +import ssl import json import logging @@ -40,7 +41,7 @@ def request(url, headers, param=None, body=None, method="POST"): try: request = Request(url=url, data=body, headers=headers) request.get_method = lambda: method.upper() - response = urlopen(request) + response = urlopen(request, context=ssl._create_unverified_context()) return response except HTTPError as err: error_msg = err.read().decode('utf-8') diff --git a/client/util/reporter.py b/client/util/reporter.py index 2258b7279..fb0e39d17 100644 --- a/client/util/reporter.py +++ b/client/util/reporter.py @@ -91,9 +91,10 @@ def update_task_progress(self, info): token = Crypto(settings.PASSWORD_KEY).decrypt(encrypted_token) dog_server = RetryDogServer(server_url, token).get_api_server(retry_times=0) - # 非节点模式,不存在NODE_ID字段,此时传参为None + # 非节点模式,NODE_ID字段传参为None + node_id = persist_data.get('NODE_ID') if self._task_scene == TaskScene.NORMAL else None dog_server.update_task_progress(self._task_params, - persist_data.get('NODE_ID'), + node_id, info.message, info.percent) except Exception as err: