You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Multi team: keycloak returns 400 error on /dags screen when teams are not defined in the keycloak client #68943
When dag bundles are assigned to teams that are not defined in the keycloak client resources keycloak returns a 400 response like the following: {"error":"invalid_resource", "error_description": "Resource with id [Dag:team-a] does not exist."}
on the /dags and / (home) screens. This is because the auth manager sends a request to keycloak to verify access to each dag by checking the resources.
edit: corrected error response as detailled in #69028
The KeycloakAuthManager or BaseAuthManager should gracefully handle 400 errors from keycloak due to missing resources for teams, and log them. This is important because if a team is added to airflow but not keycloak, all other teams will lose access to the /dags screen due to the 500 error response.
changed the title [-]Multi team: keycloak returns 500 error on /dags screen when teams are not defined in the keycloak client[/-][+]Multi team: keycloak returns 400 error on /dags screen when teams are not defined in the keycloak client[/+]on Jun 29, 2026
Activity
eladkal commentedon Jun 25, 2026
cc @vincbeck
onlyarnav commentedon Jun 26, 2026
Hi, I have submitted a PR regarding the issue. Could you please verify if that fixes the issue and its good or it still required attention.
eladkal commentedon Jun 26, 2026
Solved in #68951
stephen-bracken commentedon Jun 26, 2026
@onlyarnav thanks for working on this. I've raised #69028 to update the error message from keycloak
[-]Multi team: keycloak returns 500 error on /dags screen when teams are not defined in the keycloak client[/-][+]Multi team: keycloak returns 400 error on /dags screen when teams are not defined in the keycloak client[/+]