v1.1.52: fix scenario create (drop svcOperationId) + http_client _status debug
This commit is contained in:
@@ -105,11 +105,12 @@ class HttpClient:
|
||||
r = self._session.post(url, json=(data if data is not None else {}), **kwargs)
|
||||
if not r.ok:
|
||||
raise Exception(f"POST {path}: {r.status_code} {r.reason}: {r.text[:200]}")
|
||||
result = {}
|
||||
result = {"_status": r.status_code}
|
||||
try:
|
||||
parsed = r.json()
|
||||
if isinstance(parsed, dict):
|
||||
result = parsed
|
||||
result["_status"] = r.status_code
|
||||
except Exception:
|
||||
pass # тело не JSON или не dict — ок, Location всё равно извлечём
|
||||
loc = r.headers.get("Location", "")
|
||||
|
||||
Reference in New Issue
Block a user