Skip to content

Commit 044420c

Browse files
ambient-code[bot]claude
authored andcommitted
fix: address review feedback - remove unused import and fix namespace
- Remove unused SessionPhaseBadge import from sessions-section.tsx - Replace SessionPhaseBadge with AgentStatusIndicator using correct pattern - Fix Makefile kind-port-forward to use $(NAMESPACE) variable instead of hardcoded "ambient-code" - Simplify redundant conditional logic for agent status derivation Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 082343f commit 044420c

2 files changed

Lines changed: 9 additions & 9 deletions

File tree

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -735,8 +735,8 @@ kind-port-forward: check-kubectl check-local-context ## Port-forward kind servic
735735
@echo "$(COLOR_YELLOW)Press Ctrl+C to stop$(COLOR_RESET)"
736736
@echo ""
737737
@trap 'kill 0; echo ""; echo "$(COLOR_GREEN)✓$(COLOR_RESET) Port forwarding stopped"; exit 0' INT; \
738-
kubectl port-forward -n ambient-code svc/frontend-service $(KIND_FWD_FRONTEND_PORT):3000 >/dev/null 2>&1 & \
739-
kubectl port-forward -n ambient-code svc/backend-service $(KIND_FWD_BACKEND_PORT):8080 >/dev/null 2>&1 & \
738+
kubectl port-forward -n $(NAMESPACE) svc/frontend-service $(KIND_FWD_FRONTEND_PORT):3000 >/dev/null 2>&1 & \
739+
kubectl port-forward -n $(NAMESPACE) svc/backend-service $(KIND_FWD_BACKEND_PORT):8080 >/dev/null 2>&1 & \
740740
wait
741741

742742
dev-bootstrap: check-kubectl check-local-context ## Bootstrap developer workspace with API key and integrations

components/frontend/src/components/workspace-sections/sessions-section.tsx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ import {
2323
import { getPageNumbers } from '@/lib/pagination';
2424
import { EmptyState } from '@/components/empty-state';
2525
import { SessionStatusDot } from '@/components/session-status-dot';
26-
import { SessionPhaseBadge } from '@/components/status-badge';
2726
import { AgentStatusIndicator } from '@/components/agent-status-indicator';
2827
import { deriveAgentStatusFromPhase } from '@/hooks/use-agent-status';
2928
import { CreateSessionDialog } from '@/components/create-session-dialog';
@@ -305,7 +304,10 @@ export function SessionsSection({ projectName }: SessionsSectionProps) {
305304
<p className="text-sm font-semibold truncate mr-2">
306305
{session.spec.displayName || session.metadata.name}
307306
</p>
308-
<SessionPhaseBadge phase={phase} stoppedReason={session.status?.stoppedReason} />
307+
<AgentStatusIndicator
308+
status={session.status?.agentStatus ?? deriveAgentStatusFromPhase(phase)}
309+
compact
310+
/>
309311
</div>
310312
{session.spec.displayName && (
311313
<p className="text-xs text-muted-foreground">{session.metadata.name}</p>
@@ -333,11 +335,9 @@ export function SessionsSection({ projectName }: SessionsSectionProps) {
333335
</HoverCard>
334336
</TableCell>
335337
<TableCell>
336-
<AgentStatusIndicator status={
337-
(phase === 'Completed' || phase === 'Failed' || phase === 'Stopped')
338-
? deriveAgentStatusFromPhase(phase)
339-
: (session.status?.agentStatus ?? deriveAgentStatusFromPhase(phase))
340-
} />
338+
<AgentStatusIndicator
339+
status={session.status?.agentStatus ?? deriveAgentStatusFromPhase(phase)}
340+
/>
341341
</TableCell>
342342
<TableCell className="hidden md:table-cell">
343343
<div className="text-sm truncate max-w-[160px]">

0 commit comments

Comments
 (0)