Private
Public Access
refactor(ai_client): remove ProviderError class; ErrorInfo is the new error type
This commit is contained in:
@@ -39,12 +39,12 @@ def test_qwen_tool_format_translation() -> None:
|
||||
assert "parameters" in ds_tools[0]
|
||||
|
||||
def test_qwen_error_classification() -> None:
|
||||
from src.ai_client import ProviderError
|
||||
from src.result_types import ErrorKind
|
||||
from src.qwen_adapter import classify_dashscope_error
|
||||
from dashscope.common.error import AuthenticationError
|
||||
err = classify_dashscope_error(AuthenticationError("bad key"))
|
||||
assert err.kind == "auth"
|
||||
assert err.provider == "qwen"
|
||||
assert err.kind == ErrorKind.AUTH
|
||||
assert err.source == "qwen_adapter"
|
||||
|
||||
def test_list_qwen_models_returns_hardcoded_registry() -> None:
|
||||
from src.ai_client import _list_qwen_models
|
||||
|
||||
Reference in New Issue
Block a user