mirror of
https://github.com/hwchase17/langchain.git
synced 2025-06-29 01:48:57 +00:00
Do not await sync callback managers (#3440)
This fixes a bug in the math LLM, where even the sync manager was awaited, creating a nasty `RuntimeError`
This commit is contained in:
parent
0cf934ce7d
commit
f22b9d0e57
@ -106,8 +106,8 @@ class LLMMathChain(Chain):
|
|||||||
output, color="yellow", verbose=self.verbose
|
output, color="yellow", verbose=self.verbose
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
await self.callback_manager.on_text("\nAnswer: ", verbose=self.verbose)
|
self.callback_manager.on_text("\nAnswer: ", verbose=self.verbose)
|
||||||
await self.callback_manager.on_text(
|
self.callback_manager.on_text(
|
||||||
output, color="yellow", verbose=self.verbose
|
output, color="yellow", verbose=self.verbose
|
||||||
)
|
)
|
||||||
answer = "Answer: " + output
|
answer = "Answer: " + output
|
||||||
|
Loading…
Reference in New Issue
Block a user