[GH-ISSUE #1082] [langchain]: langchain.cache module is missing, but the documentation states the contrary #142

Closed
opened 2026-02-17 17:19:16 -05:00 by yindo · 3 comments
Owner

Originally created by @askarkg12 on GitHub (Oct 21, 2025).
Original GitHub issue: https://github.com/langchain-ai/docs/issues/1082

Type of issue

issue / bug

Language

Python

Description

According to https://docs.langchain.com/oss/python/integrations/providers/redis , functionality of langchain_redis has been moved to langchain.cache, at least this is my interpretation. Since it seems that langchain_redis was not released with support of langchain v1.0.

However, trying to import RedisCache via from langchain.cache import RedisCache results in No module named 'langchain.cache'.

Is this a documentation issue or a bug? If langchain_redis is due to be upgraded to support v1.0, then the documentation needs to be updated. Otherwise this is a bug

Originally created by @askarkg12 on GitHub (Oct 21, 2025). Original GitHub issue: https://github.com/langchain-ai/docs/issues/1082 ### Type of issue issue / bug ### Language Python ### Description According to [https://docs.langchain.com/oss/python/integrations/providers/redis](url) , functionality of `langchain_redis` has been moved to `langchain.cache`, at least this is my interpretation. Since it seems that `langchain_redis` was not released with support of `langchain v1.0`. However, trying to import RedisCache via `from langchain.cache import RedisCache` results in `No module named 'langchain.cache'`. Is this a documentation issue or a bug? If `langchain_redis` is due to be upgraded to support v1.0, then the documentation needs to be updated. Otherwise this is a bug
yindo added the langchain label 2026-02-17 17:19:16 -05:00
yindo closed this issue 2026-02-17 17:19:16 -05:00
Author
Owner

@mdrxy commented on GitHub (Oct 21, 2025):

It looks like the docs haven't been updated for Redis in a bit -- the langchain.cache RedisCache export is surfacing the cache from langchain_community for backwards compatability. It is now accessible via langchain_community.cache

However, that community cache appears outdated. I'd recommend importing from langchain_redis.RedisCache instead for the most up to date version. I will update the docs to reflect this.

@mdrxy commented on GitHub (Oct 21, 2025): It looks like the docs haven't been updated for Redis in a bit -- the `langchain.cache` `RedisCache` export is surfacing the cache from `langchain_community` for backwards compatability. It is now accessible via `langchain_community.cache` However, that community cache appears outdated. I'd recommend importing from `langchain_redis.RedisCache` instead for the most up to date version. I will update the docs to reflect this.
Author
Owner

@askarkg12 commented on GitHub (Oct 22, 2025):

Unfortunately, langchain_redis does not install on langchain 1.0:

uv add langchain_redis
× No solution found when resolving dependencies for split (markers: python_full_version >= '3.14'):
╰─▶ Because only the following versions of langchain-redis are available:
langchain-redis==0.0.1
langchain-redis==0.0.2
langchain-redis==0.0.3
langchain-redis==0.0.4
langchain-redis==0.1.0
langchain-redis==0.1.1
langchain-redis==0.1.2
langchain-redis==0.2.0
langchain-redis==0.2.1
langchain-redis==0.2.2
langchain-redis==0.2.3
langchain-redis==0.2.4
and langchain-redis<=0.0.4 depends on langchain-core>=0.1.52,<0.3, we can conclude that langchain-redis<0.1.0 depends on langchain-core>=0.1.52,<0.3.
And because langchain-redis>=0.1.0 depends on langchain-core>=0.3,<0.4, we can conclude that all versions of langchain-redis depend on langchain-core>=0.1.52,<0.4.
And because deepagents==0.1.3 depends on langchain-core>=1.0.0 and only deepagents<=0.1.3 is available, we can conclude that deepagents>=0.1.3 and all versions of langchain-redis are incompatible.
And because your project depends on deepagents>=0.1.3 and langchain-redis, we can conclude that your project's requirements are unsatisfiable.

  hint: Pre-releases are available for `langchain-redis` in the requested range (e.g., 0.0.1rc1), but pre-releases weren't enabled (try: `--prerelease=allow`)

  hint: While the active Python version is 3.13, the resolution failed for other Python versions supported by your project. Consider limiting your project's supported Python versions using `requires-python`.

help: If you want to add the package regardless of the failed resolution, provide the --frozen flag to skip locking and syncing.

@askarkg12 commented on GitHub (Oct 22, 2025): Unfortunately, `langchain_redis` does not install on `langchain 1.0`: > uv add langchain_redis > × No solution found when resolving dependencies for split (markers: python_full_version >= '3.14'): > ╰─▶ Because only the following versions of langchain-redis are available: > langchain-redis==0.0.1 > langchain-redis==0.0.2 > langchain-redis==0.0.3 > langchain-redis==0.0.4 > langchain-redis==0.1.0 > langchain-redis==0.1.1 > langchain-redis==0.1.2 > langchain-redis==0.2.0 > langchain-redis==0.2.1 > langchain-redis==0.2.2 > langchain-redis==0.2.3 > langchain-redis==0.2.4 > and langchain-redis<=0.0.4 depends on langchain-core>=0.1.52,<0.3, we can conclude that langchain-redis<0.1.0 depends on langchain-core>=0.1.52,<0.3. > And because langchain-redis>=0.1.0 depends on langchain-core>=0.3,<0.4, we can conclude that all versions of langchain-redis depend on langchain-core>=0.1.52,<0.4. > And because deepagents==0.1.3 depends on langchain-core>=1.0.0 and only deepagents<=0.1.3 is available, we can conclude that deepagents>=0.1.3 and all versions of langchain-redis are incompatible. > And because your project depends on deepagents>=0.1.3 and langchain-redis, we can conclude that your project's requirements are unsatisfiable. > > hint: Pre-releases are available for `langchain-redis` in the requested range (e.g., 0.0.1rc1), but pre-releases weren't enabled (try: `--prerelease=allow`) > > hint: While the active Python version is 3.13, the resolution failed for other Python versions supported by your project. Consider limiting your project's supported Python versions using `requires-python`. > help: If you want to add the package regardless of the failed resolution, provide the `--frozen` flag to skip locking and syncing.
Author
Owner

@mdrxy commented on GitHub (Oct 22, 2025):

@askarkg12 we still need to bump that package for v1 support - stay tuned

@mdrxy commented on GitHub (Oct 22, 2025): @askarkg12 we still need to bump that package for v1 support - stay tuned
yindo changed title from [langchain]: `langchain.cache` module is missing, but the documentation states the contrary to [GH-ISSUE #1082] [langchain]: `langchain.cache` module is missing, but the documentation states the contrary 2026-06-05 17:25:18 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langchain-ai/docs#142