mirror of
https://github.com/langchain-ai/langgraph.git
synced 2026-09-09 19:27:54 +02:00
Merge pull request #2112 from langchain-ai/vb/fix-type
langgraph: fix type for RemainingSteps
This commit is contained in:
@@ -11,9 +11,9 @@ class IsLastStepManager(ManagedValue[bool]):
|
||||
IsLastStep = Annotated[bool, IsLastStepManager]
|
||||
|
||||
|
||||
class RemainingStepsManager(ManagedValue[bool]):
|
||||
def __call__(self) -> bool:
|
||||
class RemainingStepsManager(ManagedValue[int]):
|
||||
def __call__(self) -> int:
|
||||
return self.loop.stop - self.loop.step
|
||||
|
||||
|
||||
RemainingSteps = Annotated[bool, RemainingStepsManager]
|
||||
RemainingSteps = Annotated[int, RemainingStepsManager]
|
||||
|
||||
Reference in New Issue
Block a user