Skip to content

Fix FAB auth_manager load_user causing PendingRollbackError and Inter…#61943

Merged
potiuk merged 2 commits into
apache:mainfrom
MonsterChenzhuo:fab
Feb 15, 2026
Merged

Fix FAB auth_manager load_user causing PendingRollbackError and Inter…#61943
potiuk merged 2 commits into
apache:mainfrom
MonsterChenzhuo:fab

Conversation

@MonsterChenzhuo

@MonsterChenzhuo MonsterChenzhuo commented Feb 15, 2026

Copy link
Copy Markdown
Contributor

Summary

This PR makes FabAirflowSecurityManagerOverride.load_user more robust by:

  • Safely handling cases where the user does not exist or is inactive.
  • Catching database exceptions (including PendingRollbackError), rolling back the session, and returning None instead of letting the exception bubble up.

The goal is to prevent sqlalchemy.exc.PendingRollbackError from causing 500 Internal Server Error responses on the web UI when loading the current user.


Was generative AI tooling used to co-author this PR?
  • Yes (please specify the tool below)

  • Read the Pull Request Guidelines for more information. Note: commit author/co-author name and email in commits become permanently public when merged.
  • For fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
  • When adding dependency, check compliance with the ASF 3rd Party License Policy.
  • For significant user-facing changes create newsfragment: {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

@potiuk potiuk merged commit 133738f into apache:main Feb 15, 2026
86 checks passed
choo121600 pushed a commit to choo121600/airflow that referenced this pull request Feb 22, 2026
apache#61943)

* Fix FAB auth_manager load_user causing PendingRollbackError and Internal Server Error

* Fix FAB auth_manager load_user causing PendingRollbackError and Internal Server Error

---------

Co-authored-by: zhuoyuchen <>
Subham-KRLX pushed a commit to Subham-KRLX/airflow that referenced this pull request Mar 4, 2026
apache#61943)

* Fix FAB auth_manager load_user causing PendingRollbackError and Internal Server Error

* Fix FAB auth_manager load_user causing PendingRollbackError and Internal Server Error

---------

Co-authored-by: zhuoyuchen <>
dominikhei pushed a commit to dominikhei/airflow that referenced this pull request Mar 11, 2026
apache#61943)

* Fix FAB auth_manager load_user causing PendingRollbackError and Internal Server Error

* Fix FAB auth_manager load_user causing PendingRollbackError and Internal Server Error

---------

Co-authored-by: zhuoyuchen <>
Ankurdeewan pushed a commit to Ankurdeewan/airflow that referenced this pull request Mar 15, 2026
apache#61943)

* Fix FAB auth_manager load_user causing PendingRollbackError and Internal Server Error

* Fix FAB auth_manager load_user causing PendingRollbackError and Internal Server Error

---------

Co-authored-by: zhuoyuchen <>
radhwene pushed a commit to radhwene/airflow that referenced this pull request Mar 21, 2026
apache#61943)

* Fix FAB auth_manager load_user causing PendingRollbackError and Internal Server Error

* Fix FAB auth_manager load_user causing PendingRollbackError and Internal Server Error

---------

Co-authored-by: zhuoyuchen <>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants