Unset Cache in Tests (#7362)

This is impacting other unit tests that use callbacks since the cache is
still set (just empty)
pull/7370/head^2
William FH 1 year ago committed by GitHub
parent 3ce4e46c8c
commit 4e180dc54e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -47,6 +47,7 @@ def set_cache_and_teardown(request: FixtureRequest) -> Generator[None, None, Non
# Will be run after each test
if langchain.llm_cache:
langchain.llm_cache.clear()
langchain.llm_cache = None
else:
raise ValueError("Cache not set. This should never happen.")

Loading…
Cancel
Save