langchain/libs/core/langchain_core/runnables
Chengyu Yan d0ad713937
core: fix issue#24660, slove error messages about ValueError when use model with history (#25183)
- **Description:**
This PR will slove error messages about `ValueError` when use model with
history.
Detail in #24660.
#22933 causes that
`langchain_core.runnables.history.RunnableWithMessageHistory._get_output_messages`
miss type check of `output_val` if `output_val` is `False`. After
running `RunnableWithMessageHistory._is_not_async`, `output` is `False`.

249945a572/libs/core/langchain_core/runnables/history.py (L323-L334)

15a36dd0a2/libs/core/langchain_core/runnables/history.py (L461-L471)
~~I suggest that `_get_output_messages` return empty list when
`output_val == False`.~~

- **Issue**:
  - #24660

- **Dependencies:**: No Change.

---------

Co-authored-by: Bagatur <baskaryan@gmail.com>
Co-authored-by: Eugene Yurtsev <eyurtsev@gmail.com>
2024-08-14 14:26:22 +00:00
..
__init__.py core[minor]: Add BaseModel.rate_limiter, RateLimiter abstraction and in-memory implementation (#24669) 2024-07-26 03:03:34 +00:00
base.py Set Context in RunnableSequence & RunnableParallel (#25073) 2024-08-06 11:10:37 -07:00
branch.py docs: fix kwargs docstring (#25010) 2024-08-02 19:54:54 -07:00
config.py Set Context in RunnableSequence & RunnableParallel (#25073) 2024-08-06 11:10:37 -07:00
configurable.py core[patch]: docstrings runnables update (#24161) 2024-07-12 11:27:06 -04:00
fallbacks.py Set Context in RunnableSequence & RunnableParallel (#25073) 2024-08-06 11:10:37 -07:00
graph_ascii.py core[patch]: docstrings runnables update (#24161) 2024-07-12 11:27:06 -04:00
graph_mermaid.py core[patch]: docstrings runnables update (#24161) 2024-07-12 11:27:06 -04:00
graph_png.py core: Don't draw None edge labels (#24690) 2024-07-25 22:12:39 +00:00
graph.py core: Fix implementation of trim_first_node/trim_last_node to use exact same definition of first/last node as in the getter methods (#24802) 2024-07-30 08:44:27 -07:00
history.py core: fix issue#24660, slove error messages about ValueError when use model with history (#25183) 2024-08-14 14:26:22 +00:00
learnable.py [Enhancement] Add support for directly providing a run_id (#18990) 2024-03-18 15:03:04 -07:00
passthrough.py core[patch]: docstrings runnables update (#24161) 2024-07-12 11:27:06 -04:00
retry.py core[patch]: docstrings runnables update (#24161) 2024-07-12 11:27:06 -04:00
router.py core[patch]: docstrings runnables update (#24161) 2024-07-12 11:27:06 -04:00
schema.py Docs: Add how to dispatch custom callback events (#24278) 2024-07-16 17:38:32 -04:00
utils.py Set Context in RunnableSequence & RunnableParallel (#25073) 2024-08-06 11:10:37 -07:00