Skip to content

test: cover the relayed-proxy 401 refresh-failure hint - #377

Open
masonc08 wants to merge 1 commit into
mainfrom
masonc08/relayed-proxy-401-test
Open

test: cover the relayed-proxy 401 refresh-failure hint#377
masonc08 wants to merge 1 commit into
mainfrom
masonc08/relayed-proxy-401-test

Conversation

@masonc08

Copy link
Copy Markdown
Collaborator

What

Adds the unit test that should have shipped with #374 (the relayed-proxy 401 re-auth hint), which merged without it. It covers the retry-on-401 path where the forced Databricks token refresh itself fails: it asserts the databricks auth login hint is printed and the response is still relayed. Slots into TestRetryOn401 next to the success-retry and persistent-401 cases.

Why a separate PR

#374 merged before this test was pushed. This lands it against the now-merged fix — no production code change.

Testing

uv run pytest tests/test_gateway_proxy.py -q → 24 passed (incl. the new test_failed_refresh_surfaces_reauth_hint), against the merged fix on main.

This pull request and its description were written by Isaac.

Adds test_failed_refresh_surfaces_reauth_hint to TestRetryOn401 — forces a 401 plus a
refresh that raises and asserts the `databricks auth login` hint prints and the response
is still relayed. Guards the fix commit on this branch.

Co-authored-by: Isaac <no-reply@databricks.com>
@masonc08
masonc08 requested a review from rohita5l August 24, 2026 19:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant