fix(copilot): address second CodeRabbit review cycle

- Fix docstring: default is True, not False (config_test.py)
- Redact exception message from stream-error log for consistency
  with upstream-error log (openrouter_compat_proxy.py)
This commit is contained in:
majdyz
2026-04-12 07:31:45 +00:00
parent 85f64de4cf
commit cc3bac13c5
2 changed files with 4 additions and 2 deletions

View File

@@ -131,7 +131,7 @@ class TestClaudeAgentUseCompatProxyEnvFallback:
prefixed ``CHAT_CLAUDE_AGENT_USE_COMPAT_PROXY`` env var and the
unprefixed ``CLAUDE_AGENT_USE_COMPAT_PROXY`` form. Regression
guard for the bool-default pitfall: the field has a non-None
default (``False``), so Pydantic passes the default into the
default (``True``), so Pydantic passes the default into the
validator when no value is provided and a naive ``if v is None``
check would never fire.
"""

View File

@@ -463,7 +463,9 @@ class OpenRouterCompatProxy:
raise
except aiohttp.ClientError as e:
stream_error = e
logger.warning("OpenRouter compat proxy stream interrupted: %s", e)
logger.warning(
"OpenRouter compat proxy stream interrupted: %s", type(e).__name__
)
finally:
if not cancelled:
upstream_response.release()