fix(providers/fab): restore OAuth callback route exposure#62150
Closed
tschroeder-zendesk wants to merge 1 commit intoapache:mainfrom
Closed
fix(providers/fab): restore OAuth callback route exposure#62150tschroeder-zendesk wants to merge 1 commit intoapache:mainfrom
tschroeder-zendesk wants to merge 1 commit intoapache:mainfrom
Conversation
Restore the oauth-authorized route on CustomAuthOAuthView so URL building succeeds when FAB overrides AuthOAuthView. Add a regression test to ensure the callback endpoint remains registered. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Congratulations on your first Pull Request and welcome to the Apache Airflow community! If you have any issues or are unsure about any anything please check our Contributors' Guide (https://github.com/apache/airflow/blob/main/contributing-docs/README.rst)
|
Author
Author
|
Closing in favor of #62151 (same fix, correct updated diff). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Restore OAuth callback route registration on
CustomAuthOAuthView.CustomAuthOAuthView.oauth_authorizedoverrides FAB'sAuthOAuthView.oauth_authorized, but without re-applying the@expose("/oauth-authorized/<provider>")decorator the callback endpoint is not registered on the custom view. This breaks URL generation forCustomAuthOAuthView.oauth_authorizedduring OAuth login.This PR re-adds the route decorator and includes a regression unit test asserting the callback route remains exposed.
Fixes #62028
Testing
source .venv/bin/activate && ruff check providers/fab/src/airflow/providers/fab/auth_manager/views/auth_oauth.py providers/fab/tests/unit/fab/auth_manager/views/test_auth_oauth.pybreeze run --python 3.12 --platform linux/amd64 --tty disabled --skip-image-upgrade-check -- python -m pytest providers/fab/tests/unit/fab/auth_manager/views/test_auth_oauth.py -qWas generative AI tooling used to co-author this PR?
Generated-by: Cursor (GPT-5.3) following the guidelines
{pr_number}.significant.rstor{issue_number}.significant.rst, in airflow-core/newsfragments.