timeout,ruff
All checks were successful
deploy / deploy (push) Successful in 1m7s

This commit is contained in:
2023-10-17 18:22:05 +03:00
parent 7a561603ed
commit 878c0dc216
2 changed files with 13 additions and 2 deletions

View File

@@ -4,7 +4,7 @@ from httpx import AsyncClient, HTTPError
from settings import AUTH_URL
INTERNAL_AUTH_SERVER = "v2.discours" in AUTH_URL or "testapi.discours" in AUTH_URL
INTERNAL_AUTH_SERVER = "auth.discours.io" not in AUTH_URL
async def check_auth(req):
@@ -23,7 +23,7 @@ async def check_auth(req):
"variables": None,
}
async with AsyncClient() as client:
async with AsyncClient(timeout=30.0) as client:
response = await client.post(AUTH_URL, headers=headers, json=gql)
print(f"[services.auth] response: {response.status_code} {response.text}")
if response.status_code != 200: