mirror of
https://github.com/Significant-Gravitas/AutoGPT.git
synced 2026-04-08 03:00:28 -04:00
Disable close_context_item when context is empty
This commit is contained in:
@@ -53,7 +53,7 @@ def task_complete(reason: str, agent: Agent) -> None:
|
||||
"required": True,
|
||||
}
|
||||
},
|
||||
available=lambda a: get_agent_context(a) is not None,
|
||||
available=lambda a: bool(get_agent_context(a)),
|
||||
)
|
||||
def close_context_item(index: int, agent: Agent) -> str:
|
||||
assert (context := get_agent_context(agent)) is not None
|
||||
|
||||
Reference in New Issue
Block a user