The GitHub Actions job "Tests (AMD)" on airflow.git/ctl-json-media-type-errors 
has succeeded.
Run started by GitHub user rjgoyln (triggered by rjgoyln).

Head commit for run:
1c5b4051024d6acdd13284bbde8703c8de1a442d / rjgoyln <[email protected]>
Fix airflowctl tracebacks on JSON errors behind a reverse proxy

airflowctl compared the error response content-type against the exact
string "application/json". Any reverse proxy, ingress, or API gateway
that returns "application/json; charset=utf-8" — or emits its own
"application/problem+json" error — fell outside that comparison, so
ServerResponseError was never constructed and the friendly "not found"
messages in the dags and tasks commands were skipped. The bare
httpx.HTTPStatusError raised instead is not handled by
safe_call_command, so users saw a raw traceback. Airflow's own API
server does not send a charset, which is why this only surfaces once
something sits in front of it.

Media types are case-insensitive and may carry parameters (RFC 9110),
so the header has to be parsed rather than compared whole.

Matching more responses also routes bodies into the error path that are
valid JSON but not objects, which dict() rejected with a ValueError from
that same unprotected path, and bodies that do not decode at all.

Report URL: https://github.com/apache/airflow/actions/runs/30735197222

With regards,
GitHub Actions via GitBox


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to