{"record":{"id":"512f04ef10209263","repo":"apache/beam","slug":"failed-to-make-node-v-with-node-id-v","errorCode":null,"errorMessage":"failed to make node %v with node id %v","messagePattern":"failed to make node (.+?) with node id (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"sdks/go/pkg/beam/core/runtime/graphx/translate.go","lineNumber":1183,"sourceCode":"\nfunc (m *marshaller) addNode(n *graph.Node) (string, error) {\n\tid := nodeID(n)\n\tif _, exists := m.pcollections[id]; exists {\n\t\treturn id, nil\n\t}\n\t// TODO(herohde) 11/15/2017: expose UniqueName to user.\n\tcid, err := m.coders.Add(n.Coder)\n\tif err != nil {\n\t\treturn \"\", err\n\t}\n\treturn m.makeNode(id, cid, n)\n}\n\nfunc (m *marshaller) makeNode(id, cid string, n *graph.Node) (string, error) {\n\twindowingStrategyId, err := m.addWindowingStrategy(n.WindowingStrategy())\n\n\tif err != nil {\n\t\treturn \"\", errors.Wrapf(err, \"failed to make node %v with node id %v\", n, id)\n\t}\n\n\tcol := &pipepb.PCollection{\n\t\tUniqueName:          id,\n\t\tCoderId:             cid,\n\t\tIsBounded:           boolToBounded(n.Bounded()),\n\t\tWindowingStrategyId: windowingStrategyId,\n\t}\n\tm.pcollections[id] = col\n\treturn id, nil\n}\n\nfunc boolToBounded(bounded bool) pipepb.IsBounded_Enum {\n\tif bounded {\n\t\treturn pipepb.IsBounded_BOUNDED\n\t}\n\treturn pipepb.IsBounded_UNBOUNDED\n}","sourceCodeStart":1165,"sourceCodeEnd":1201,"githubUrl":"https://github.com/apache/beam/blob/12126d8942aaf848030c478b4c6a28c6af861c66/sdks/go/pkg/beam/core/runtime/graphx/translate.go#L1165-L1201","documentation":"makeNode converts a graph.Node into a pipepb.PCollection. First it must register the node's windowing strategy via addWindowingStrategy; if that fails the error is wrapped as 'failed to make node %v with node id %v'. Called from expandCoGBK, expandReshuffle, and addNode, it is the choke point for all PCollection creation during marshalling.","triggerScenarios":"Any PCollection whose WindowingStrategy fails MarshalWindowingStrategy — e.g. custom window functions, unsupported trigger/closure/accumulation combos — passed through addNode while marshalling the pipeline.","commonSituations":"Using unsupported windowing (custom WindowFn) or unusual trigger settings on a PCollection; SDK version where a windowing feature isn't marshalable; corrupted graph nodes from manual graph construction.","solutions":["Read the wrapped inner error — the root cause is almost always in MarshalWindowingStrategy","Ensure PCollections use standard windowing functions (Global, Fixed, Sliding, Sessions)","Avoid unsupported trigger/accumulation mode combinations on windows","Upgrade the Go SDK if you rely on recently added windowing features"],"exampleFix":"null","handlingStrategy":"try-catch","validationCode":"// all PCollections must carry a marshalable windowing strategy\nif n.WindowingStrategy() == nil || !isSupportedWindow(n.WindowingStrategy().Fn()) {\n    return errors.New(\"node windowing strategy not marshalable\")\n}","typeGuard":"func marshalableNode(n *graph.Node) bool {\n    return n != nil && n.WindowingStrategy() != nil\n}","tryCatchPattern":"if err := beam.Run(ctx, pr); err != nil {\n    if strings.Contains(err.Error(), \"failed to make node\") {\n        // root cause is in the wrapped windowing-strategy error\n        log.Printf(\"node creation failed; check windowing: %+v\", err)\n    }\n    return err\n}","preventionTips":["Stick to standard window functions and triggers","Avoid manually mutating graph nodes","Test pipeline marshalling locally before runner submission"],"tags":["go","apache-beam","pcollection","windowing-strategy"],"backgroundTag":"unexpected-response-shape","analyzedSha":"12126d8942aaf848030c478b4c6a28c6af861c66","analyzedAt":"2026-09-13T01:50:10.254Z","contentChangedAt":"2026-09-13T01:50:10.254Z","schemaVersion":2},"datasetVersion":"2026-09-20T03:17:13.778Z"}