Wrap Google and Anthropic provider responses in JSONResponse
GoogleProviderHandler: - Wrap validated response dict in JSONResponse before returning - Add logging to confirm JSONResponse is being returned - Ensures proper JSON serialization for Google GenAI responses AnthropicProviderHandler: - Wrap validated response dict in JSONResponse before returning - Add logging to confirm JSONResponse is being returned - Ensures proper JSON serialization for Anthropic responses RequestHandler: - Remove JSONResponse wrapping (now handled by providers) - Update logging to detect JSONResponse vs dict responses - OpenAI and Ollama providers return raw dicts (already compatible) This fixes client-side 'Cannot read properties of undefined' errors by ensuring Google and Anthropic responses are properly serialized as JSONResponse, while leaving OpenAI and Ollama responses as-is since they're already OpenAI-compatible.
Showing
Please
register
or
sign in
to comment