test(bearer): expect the no-credentials 401 at ATTACH, not on a later query#2
Closed
rustyconover wants to merge 1 commit into
Closed
test(bearer): expect the no-credentials 401 at ATTACH, not on a later query#2rustyconover wants to merge 1 commit into
rustyconover wants to merge 1 commit into
Conversation
… query The extension calls catalog_attach eagerly during ATTACH, so when a bearer-protected server returns 401 without an OAuth challenge, vgi_http_client raises the actionable "advertised no OAuth challenge" diagnostic at ATTACH time (it can only produce the clean message while the URL is in scope). The test previously expected ATTACH to succeed and the error to surface on a following SELECT, which fails against the worker — the ATTACH itself raises. Make the no-credentials case a `statement error` on the ATTACH expecting the same message. Verified against the vgi-python reference worker (full pass). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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.
bearer_auth/bearer_token.testexpected ATTACH without credentials to succeed and the auth error to surface on a followingSELECT. But the extension callscatalog_attacheagerly duringATTACH, so a bearer-protected server's 401 (no OAuth challenge) is raised right there —src/vgi_http_client.cpp:455produces the actionable "advertised no OAuth challenge" diagnostic while the URL is still in scope. The oldstatement okATTACH therefore fails against the worker (it raises), against both the vgi-python and Java workers.This makes the no-credentials case a
statement erroron the ATTACH, expecting the same message. Raising at attach is the intended behavior; the test was just structured for a deferred-auth model that doesn't match.Verified against the vgi-python reference worker (full pass, unmasked).
🤖 Generated with Claude Code