mirror of
https://github.com/langchain-ai/langgraph.git
synced 2026-09-28 12:35:08 +02:00
Improve tracing output, update for newer runnables features,
This commit is contained in:
+2
-2
@@ -94,14 +94,14 @@ class RunnableSubscriber(RunnableBinding[T, Any]):
|
||||
raise NotImplementedError()
|
||||
|
||||
|
||||
class RunnablePublisher(RunnablePassthrough[T]):
|
||||
class RunnablePublisher(Runnable[T, T]):
|
||||
topic: Topic[T]
|
||||
|
||||
def invoke(self, input: T, config: Optional[RunnableConfigForPubSub] = None) -> T:
|
||||
send = config.get(CONFIG_SEND_KEY, None)
|
||||
if send is not None:
|
||||
send(self.topic.name, input)
|
||||
return super().invoke(input, config)
|
||||
return input
|
||||
|
||||
|
||||
class RunnablePublisherEach(RunnablePublisher[Sequence[T]]):
|
||||
|
||||
Reference in New Issue
Block a user