{"record":{"id":"b7d3b3eda39cce84","repo":"dotnet/reactive","slug":"source12","errorCode":null,"errorMessage":"source12","messagePattern":"source12","errorType":"validation","errorClass":"ArgumentNullException","httpStatus":null,"severity":"error","filePath":"Rx.NET/Source/src/System.Reactive/Linq/Observable.Multiple.Zip.cs","lineNumber":908,"sourceCode":"\n            if (source9 == null)\n            {\n                throw new ArgumentNullException(nameof(source9));\n            }\n\n            if (source10 == null)\n            {\n                throw new ArgumentNullException(nameof(source10));\n            }\n\n            if (source11 == null)\n            {\n                throw new ArgumentNullException(nameof(source11));\n            }\n\n            if (source12 == null)\n            {\n                throw new ArgumentNullException(nameof(source12));\n            }\n\n            if (source13 == null)\n            {\n                throw new ArgumentNullException(nameof(source13));\n            }\n\n            if (source14 == null)\n            {\n                throw new ArgumentNullException(nameof(source14));\n            }\n\n            if (resultSelector == null)\n            {\n                throw new ArgumentNullException(nameof(resultSelector));\n            }\n\n            return s_impl.Zip(source1, source2, source3, source4, source5, source6, source7, source8, source9, source10, source11, source12, source13, source14, resultSelector);","sourceCodeStart":890,"sourceCodeEnd":926,"githubUrl":"https://github.com/dotnet/reactive/blob/94b5d5ab912789f5abe9a72138a25bbd716fe59c/Rx.NET/Source/src/System.Reactive/Linq/Observable.Multiple.Zip.cs#L890-L926","documentation":"System.ArgumentNullException thrown by the 14-source public Zip overload in Observable.Multiple.Zip.cs when the twelfth source sequence (source12) is null. Each Zip input must be a valid IObservable so the operator can subscribe and buffer elements pairwise; null inputs are rejected eagerly at operator-creation time. This is standard Rx argument validation, thrown before any subscription happens.","triggerScenarios":"Calling Observable.Zip(s1, ..., s12, ..., s14, resultSelector) with the twelfth argument set to a null IObservable reference.","commonSituations":"A merged telemetry stream that was conditionally assigned and left null; wiring many sources from a config file where one key was missing and the lookup returned null; code-generation or templating that emitted a null argument placeholder.","solutions":["Initialize source12 to a valid observable before the Zip call.","Use Observable.Empty<T>() to represent an intentionally absent stream.","Add an explicit null guard for source12 before the call to get a stack trace at your code.","Move to the collection-based Zip overload and filter/assert nulls in the collection first."],"exampleFix":"// before\nvar zipped = Observable.Zip(s1, s2, s3, s4, s5, s6, s7, s8, s9, s10, s11, s12, s13, s14, selector); // s12 == null\n// after\nArgumentNullException.ThrowIfNull(s12);\nvar zipped = Observable.Zip(s1, s2, s3, s4, s5, s6, s7, s8, s9, s10, s11, s12, s13, s14, selector);","handlingStrategy":"validation","validationCode":"if (s12 is null) throw new ArgumentNullException(nameof(s12));","typeGuard":"static bool IsValidSource<T>(IObservable<T>? s) => s is not null;","tryCatchPattern":"try { var zipped = Observable.Zip(s1, ..., s12, ..., s14, selector); } catch (ArgumentNullException ex) when (ex.ParamName == \"source12\") { // replace null source with Observable.Empty<T>() }","preventionTips":["Check factory/config lookups for null before feeding results into Zip.","Keep large Zip argument lists in an ordered array so positions and nulls are auditable.","Add unit tests that cover every source slot being populated.","Fail fast in your own code with ArgumentNullException.ThrowIfNull for clearer diagnostics."],"tags":["argumentnull","zip","observables","null-check","system-reactive"],"backgroundTag":"null-argument","analyzedSha":"94b5d5ab912789f5abe9a72138a25bbd716fe59c","analyzedAt":"2026-09-15T02:26:24.759Z","contentChangedAt":"2026-09-15T02:26:24.759Z","schemaVersion":2},"datasetVersion":"2026-09-15T23:17:13.987Z"}