httpx client not varify and no timeout

This commit is contained in:
zhangjiexian 2023-03-16 15:29:33 +08:00
parent 709947bce4
commit 5b9acb6864
1 changed files with 2 additions and 2 deletions

View File

@ -7,7 +7,7 @@ from . import consts as c, utils, exceptions
class Client(object): class Client(object):
def __init__(self, api_key = '-1', api_secret_key = '-1', passphrase = '-1', use_server_time=False, flag='1', base_api = 'https://www.okx.com',debug = 'True'): def __init__(self, api_key = '-1', api_secret_key = '-1', passphrase = '-1', use_server_time=False, flag='1', base_api = 'https://www.okx.com',debug = False):
self.API_KEY = api_key self.API_KEY = api_key
self.API_SECRET_KEY = api_secret_key self.API_SECRET_KEY = api_secret_key
@ -16,7 +16,7 @@ class Client(object):
self.flag = flag self.flag = flag
self.domain = base_api self.domain = base_api
self.debug = debug self.debug = debug
self.client = httpx.Client(base_url=base_api, http2=True) self.client = httpx.Client(base_url=base_api, http2=True, verify=False, timeout=None)
def _request(self, method, request_path, params): def _request(self, method, request_path, params):
if method == c.GET: if method == c.GET: