mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-10 01:25:21 +00:00
Automatic style fix
This commit is contained in:
parent
855f0abcf9
commit
a0b384bc48
@ -165,13 +165,13 @@ def execute_query_https(
|
||||
query, user, enable_ssl_auth=True, cert_name=None, password=None
|
||||
):
|
||||
url = f"https://{instance.ip_address}:{HTTPS_PORT}/?query={query}"
|
||||
headers = {"X-ClickHouse-User":user}
|
||||
headers = {"X-ClickHouse-User": user}
|
||||
if enable_ssl_auth:
|
||||
headers["X-ClickHouse-SSL-Certificate-Auth"] = "on"
|
||||
if password:
|
||||
headers["X-ClickHouse-Key"] = password
|
||||
http_client=urllib3.PoolManager(ssl_context=get_ssl_context(cert_name))
|
||||
response = http_client.request('GET', url, headers=headers)
|
||||
http_client = urllib3.PoolManager(ssl_context=get_ssl_context(cert_name))
|
||||
response = http_client.request("GET", url, headers=headers)
|
||||
if response.status != 200:
|
||||
raise Exception(response.status)
|
||||
return response.data.decode("utf-8")
|
||||
|
Loading…
Reference in New Issue
Block a user