File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -170,9 +170,7 @@ func GetPodStatus(pod *kcore.Pod) PodStatus {
170170 numFailed := 0
171171 numKilled := 0
172172 for _ , containerStatus := range pod .Status .ContainerStatuses {
173- if containerStatus .State .Waiting != nil {
174- numWaiting ++
175- } else if containerStatus .State .Running != nil {
173+ if containerStatus .State .Running != nil {
176174 if containerStatus .Ready {
177175 numRunning ++
178176 } else {
@@ -197,7 +195,8 @@ func GetPodStatus(pod *kcore.Pod) PodStatus {
197195 numFailed ++
198196 }
199197 } else {
200- return PodStatusUnknown
198+ // either containerStatus.State.Waiting != nil or all containerStatus.States are nil (which implies waiting)
199+ numWaiting ++
201200 }
202201 }
203202 if numKilled > 0 {
You can’t perform that action at this time.
0 commit comments