mirror of
https://github.com/hwchase17/langchain.git
synced 2025-06-28 01:19:31 +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
|
||||
)
|
||||
else:
|
||||
await self.callback_manager.on_text("\nAnswer: ", verbose=self.verbose)
|
||||
await self.callback_manager.on_text(
|
||||
self.callback_manager.on_text("\nAnswer: ", verbose=self.verbose)
|
||||
self.callback_manager.on_text(
|
||||
output, color="yellow", verbose=self.verbose
|
||||
)
|
||||
answer = "Answer: " + output
|
||||
|
Loading…
Reference in New Issue
Block a user