Skip to content

Commit f2f69bb

Browse files
committed
Fix the agent status
1 parent 3b26aa0 commit f2f69bb

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

site/src/components/Resources/AgentStatus.tsx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,11 @@ const OffLifecycle: React.FC = () => {
244244
const ConnectedStatus: React.FC<{
245245
agent: WorkspaceAgent;
246246
}> = ({ agent }) => {
247+
// This is to support legacy agents that do not support
248+
// reporting the lifecycle_state field.
249+
if (agent.scripts.length === 0) {
250+
return <ReadyLifecycle />;
251+
}
247252
return (
248253
<ChooseOne>
249254
<Cond condition={agent.lifecycle_state === "ready"}>

0 commit comments

Comments
 (0)