Skip to content

Commit cd0283b

Browse files
committed
Fix playground is_paused
1 parent 51d2960 commit cd0283b

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

libs/agno/agno/app/playground/async_router.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@ async def get_agent_session(agent_id: str, session_id: str, user_id: Optional[st
407407
if runs is not None:
408408
first_run = runs[0]
409409
# This is how we know it is a RunResponse
410-
if "content" in first_run or first_run.is_paused:
410+
if "content" in first_run or first_run.get("is_paused", False):
411411
agent_session_dict["runs"] = []
412412

413413
for run in runs:
@@ -782,7 +782,7 @@ async def get_team_session(team_id: str, session_id: str, user_id: Optional[str]
782782
if runs is not None:
783783
first_run = runs[0]
784784
# This is how we know it is a RunResponse
785-
if "content" in first_run or first_run.is_paused:
785+
if "content" in first_run or first_run.get("is_paused", False):
786786
team_session_dict["runs"] = []
787787
for run in runs:
788788
first_user_message = None

libs/agno/agno/app/playground/sync_router.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ def get_agent_session(agent_id: str, session_id: str, user_id: Optional[str] = Q
403403
runs = agent_session.memory.get("runs")
404404
if runs is not None:
405405
first_run = runs[0]
406-
if "content" in first_run or first_run.is_paused:
406+
if "content" in first_run or first_run.get("is_paused", False):
407407
agent_session_dict["runs"] = []
408408
for run in runs:
409409
first_user_message = None
@@ -775,7 +775,7 @@ def get_team_session(team_id: str, session_id: str, user_id: Optional[str] = Que
775775
runs = team_session.memory.get("runs")
776776
if runs is not None:
777777
first_run = runs[0]
778-
if "content" in first_run or first_run.is_paused:
778+
if "content" in first_run or first_run.get("is_paused", False):
779779
team_session_dict["runs"] = []
780780
for run in runs:
781781
first_user_message = None

0 commit comments

Comments
 (0)