From ffbe7331f6ef9b302921ab11d5bebd5fd5528311 Mon Sep 17 00:00:00 2001 From: cyril-ui-developer Date: Mon, 19 Jan 2026 14:54:23 -0500 Subject: [PATCH] '0 of pods' are shown in Status column on DaemonSets list page. --- frontend/public/components/workload-table.tsx | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/frontend/public/components/workload-table.tsx b/frontend/public/components/workload-table.tsx index f6686c7b537..22ff74c0f2b 100644 --- a/frontend/public/components/workload-table.tsx +++ b/frontend/public/components/workload-table.tsx @@ -86,11 +86,21 @@ const tableColumnInfo = [ export const ReplicasCount: React.FCC = ({ obj, kind }) => { const { t } = useTranslation(); + + // DaemonSets use different status fields than Deployments + const isDaemonSet = kind?.includes('DaemonSet'); + const statusReplicas = isDaemonSet + ? obj.status?.currentNumberScheduled ?? 0 + : obj.status?.replicas ?? 0; + const specReplicas = isDaemonSet + ? obj.status?.desiredNumberScheduled ?? 0 + : obj.spec?.replicas ?? 0; + return ( {t('public~{{statusReplicas}} of {{specReplicas}} pods', { - statusReplicas: obj.status.replicas || 0, - specReplicas: obj.spec.replicas, + statusReplicas, + specReplicas, })} );