Error2 reports
Fix FakeListChatModelError
in LangChain
✅ Solution
The "FakeListChatModelError" usually indicates an inconsistency in the expected structure versus the actual output of a fake list chat model, especially when dealing with streaming responses. Specifically, the tests often expect an empty list `[]` when no data is streamed (like an error), but the model mistakenly returns a list containing an empty list `[[]]`. Modify the fake models or mocks involved in the test to return an empty list `[]` instead of a list containing an empty list `[[]]` when simulating an empty stream or error condition.
Related Issues
Real GitHub issues where developers encountered this error:
Timeline
First reported:21h ago
Last reported:21h ago