Skip to content

Commit

Permalink
Avoid nil pointer for 2.0 workflows. (#820)
Browse files Browse the repository at this point in the history
  • Loading branch information
mthx authored and jessesuen committed Apr 5, 2018
1 parent 0f225ce commit da582a5
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cmd/argo/commands/get.go
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,10 @@ func convertToRenderTrees(wf *wfv1.Workflow) map[string]renderNode {

// 1st Pass Process enough of nonBoundaryParent nodes to know all their children
for id, status := range wf.Status.Nodes {
if status.Type == "" {
log.Fatal("Missing node type in status node. Cannot get workflows created with Argo <= 2.0 using the default or wide output option.")
return nil
}
if isNonBoundaryParentNode(status.Type) {
n := nonBoundaryParentNode{nodeInfo: nodeInfo{id: id}}
nonBoundaryParentMap[id] = &n
Expand Down

0 comments on commit da582a5

Please sign in to comment.