Co-authored-by: Charles-Edouard Cady <charles.edouard.cady@mistral.ai>
Co-authored-by: Guillaume LE GOFF <guillaume.lgf@gmail.com>
Co-authored-by: Pierre Rossinès <pierre.rossines@mistral.ai>
Co-authored-by: Sylvain Afchain <safchain@gmail.com>
Co-authored-by: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
Mathias Gesbert 2026-06-29 17:14:25 +02:00 committed by GitHub
parent e607ccbb00
commit ed5b7192e6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
33 changed files with 1456 additions and 125 deletions

View file

@ -190,6 +190,18 @@ class TestKeyringTokenStorage:
assert "api_key_env" in msg
assert exc_info.value.server_alias == "linear"
def test_unloadable_backend_raises_headless(self) -> None:
# PYTHON_KEYRING_BACKEND can point at a backend module that is absent from
# Vibe's isolated venv (e.g. flyte._keyring.file in Flyte/Slurm envs), so
# get_keyring() raises ModuleNotFoundError instead of returning a backend.
with patch(
"vibe.core.auth.mcp_oauth.keyring.get_keyring",
side_effect=ModuleNotFoundError("No module named 'flyte'"),
):
with pytest.raises(MCPOAuthHeadlessError) as exc_info:
KeyringTokenStorage(alias="notion")
assert exc_info.value.server_alias == "notion"
class TestFingerprint:
def test_compute_stable_across_scope_order(