Regression in VectorStoreQATool and VectorStoreQAWithSourcesTool #18460
Labels
🤖:bug
Related to a bug, vulnerability, unexpected error with an existing feature
Ɑ: vector store
Related to vector store module
Checked other resources
Example Code
;
Error Message and Stack Trace (if applicable)
Root cause:
AttributeError: 'CallbackManager' object has no attribute 'ignore_chain'
`
Traceback (most recent call last):
File "/var/lang/lib/python3.10/site-packages/langchain_core/callbacks/manager.py", line 255, in handle_event
if ignore_condition_name is None or not getattr(
AttributeError: 'CallbackManager' object has no attribute 'ignore_chain'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/var/lang/lib/python3.10/site-packages/langchain_core/runnables/base.py", line 2075, in invoke
input = step.invoke(
File "/var/lang/lib/python3.10/site-packages/langchain_core/runnables/base.py", line 4069, in invoke
return self.bound.invoke(
File "/var/lang/lib/python3.10/site-packages/langchain/chains/base.py", line 163, in invoke
raise e
File "/var/lang/lib/python3.10/site-packages/langchain/chains/base.py", line 153, in invoke
self._call(inputs, run_manager=run_manager)
File "/var/lang/lib/python3.10/site-packages/langchain/agents/agent.py", line 1391, in _call
next_step_output = self._take_next_step(
File "/var/lang/lib/python3.10/site-packages/langchain/agents/agent.py", line 1097, in _take_next_step
[
File "/var/lang/lib/python3.10/site-packages/langchain/agents/agent.py", line 1097, in
[
File "/var/lang/lib/python3.10/site-packages/langchain/agents/agent.py", line 1182, in _iter_next_step
yield self._perform_agent_action(
File "/var/lang/lib/python3.10/site-packages/langchain/agents/agent.py", line 1204, in _perform_agent_action
observation = tool.run(
File "/var/lang/lib/python3.10/site-packages/langchain_core/tools.py", line 419, in run
raise e
File "/var/lang/lib/python3.10/site-packages/langchain_core/tools.py", line 376, in run
self._run(*tool_args, run_manager=run_manager, **tool_kwargs)
File "/var/lang/lib/python3.10/site-packages/langchain_community/tools/vectorstore/tool.py", line 57, in _run
return chain.invoke(
File "/var/lang/lib/python3.10/site-packages/langchain/chains/base.py", line 145, in invoke
run_manager = callback_manager.on_chain_start(
File "/var/lang/lib/python3.10/site-packages/langchain_core/callbacks/manager.py", line 1296, in on_chain_start
handle_event(
File "/var/lang/lib/python3.10/site-packages/langchain_core/callbacks/manager.py", line 285, in handle_event
if handler.raise_error:
AttributeError: 'CallbackManager' object has no attribute 'raise_error'
`
Description
Patch #16949 introduced breaking change.
See my comment their #16949 (comment)
System Info
bash-4.2# python -m langchain_core.sys_info
System Information
Package Information
Packages not installed (Not Necessarily a Problem)
The following packages were not found:
The text was updated successfully, but these errors were encountered: