dstandish commented on code in PR #37851:
URL: https://github.com/apache/airflow/pull/37851#discussion_r1510092644
##########
airflow/api_internal/internal_api_call.py:
##########
@@ -100,10 +100,11 @@ def internal_api_call(func: Callable[PS, RT]) ->
Callable[PS, RT]:
def make_jsonrpc_request(method_name: str, params_json: str) -> bytes:
data = {"jsonrpc": "2.0", "method": method_name, "params": params_json}
internal_api_endpoint = InternalApiConfig.get_internal_api_endpoint()
+ # print(f"{headers=}")
response = requests.post(url=internal_api_endpoint,
data=json.dumps(data), headers=headers)
if response.status_code != 200:
raise AirflowException(
- f"Got {response.status_code}:{response.reason} when sending
the internal api request."
+ f"Got {response.status_code}:{response.reason} when sending
the internal api request: {response.content.decode('utf-8')}"
Review Comment:
the actual reason for the error is stored in `response.content`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]