{"record":{"id":"3916744413ded64a","repo":"dotnet/reactive","slug":"throw-new-argumentnullexception-nameof-fourteenth","errorCode":null,"errorMessage":"throw new ArgumentNullException(nameof(fourteenth))","messagePattern":"throw new ArgumentNullException\\(nameof\\(fourteenth\\)\\)","errorType":"exception","errorClass":"ArgumentNullException","httpStatus":null,"severity":"error","filePath":"Rx.NET/Source/src/System.Reactive/Linq/QbservableEx.Homoicon.cs","lineNumber":922,"sourceCode":"                throw new ArgumentNullException(nameof(fifth));\n            if (sixth == null)\n                throw new ArgumentNullException(nameof(sixth));\n            if (seventh == null)\n                throw new ArgumentNullException(nameof(seventh));\n            if (eighth == null)\n                throw new ArgumentNullException(nameof(eighth));\n            if (ninth == null)\n                throw new ArgumentNullException(nameof(ninth));\n            if (tenth == null)\n                throw new ArgumentNullException(nameof(tenth));\n            if (eleventh == null)\n                throw new ArgumentNullException(nameof(eleventh));\n            if (twelfth == null)\n                throw new ArgumentNullException(nameof(twelfth));\n            if (thirteenth == null)\n                throw new ArgumentNullException(nameof(thirteenth));\n            if (fourteenth == null)\n                throw new ArgumentNullException(nameof(fourteenth));\n            if (fifteenth == null)\n                throw new ArgumentNullException(nameof(fifteenth));\n            if (sixteenth == null)\n                throw new ArgumentNullException(nameof(sixteenth));\n\n            return first.Provider.CreateQuery<(TFirst First, TSecond Second, TThird Third, TFourth Fourth, TFifth Fifth, TSixth Sixth, TSeventh Seventh, TEighth Eighth, TNinth Ninth, TTenth Tenth, TEleventh Eleventh, TTwelfth Twelfth, TThirteenth Thirteenth, TFourteenth Fourteenth, TFifteenth Fifteenth, TSixteenth Sixteenth)>(\n                Expression.Call(\n                    null,\n                    new Func<IQbservable<TFirst>, IObservable<TSecond>, IObservable<TThird>, IObservable<TFourth>, IObservable<TFifth>, IObservable<TSixth>, IObservable<TSeventh>, IObservable<TEighth>, IObservable<TNinth>, IObservable<TTenth>, IObservable<TEleventh>, IObservable<TTwelfth>, IObservable<TThirteenth>, IObservable<TFourteenth>, IObservable<TFifteenth>, IObservable<TSixteenth>, IQbservable<(TFirst First, TSecond Second, TThird Third, TFourth Fourth, TFifth Fifth, TSixth Sixth, TSeventh Seventh, TEighth Eighth, TNinth Ninth, TTenth Tenth, TEleventh Eleventh, TTwelfth Twelfth, TThirteenth Thirteenth, TFourteenth Fourteenth, TFifteenth Fifteenth, TSixteenth Sixteenth)>>(CombineLatest<TFirst, TSecond, TThird, TFourth, TFifth, TSixth, TSeventh, TEighth, TNinth, TTenth, TEleventh, TTwelfth, TThirteenth, TFourteenth, TFifteenth, TSixteenth>).Method,\n                    first.Expression,\n                    GetSourceExpression(second),\n                    GetSourceExpression(third),\n                    GetSourceExpression(fourth),\n                    GetSourceExpression(fifth),\n                    GetSourceExpression(sixth),\n                    GetSourceExpression(seventh),\n                    GetSourceExpression(eighth),\n                    GetSourceExpression(ninth),","sourceCodeStart":904,"sourceCodeEnd":940,"githubUrl":"https://github.com/dotnet/reactive/blob/94b5d5ab912789f5abe9a72138a25bbd716fe59c/Rx.NET/Source/src/System.Reactive/Linq/QbservableEx.Homoicon.cs#L904-L940","documentation":"System.ArgumentNullException raised by the null-guard for the fourteenth source in a CombineLatest overload in QbservableEx.Homoicon.cs. The overload's validation chain rejected the call because the fourteenth source was null; the CreateQuery expression tree was never built.","triggerScenarios":"Invoking the 14+ argument Qbservable.CombineLatest overload with fourteenth == null at line 922 of the guard chain.","commonSituations":"Very large source compositions assembled from conditional lists; one stream dependency missing at runtime (uninitialized service, failed subscription setup).","solutions":["Provide a valid fourteenth IQbservable argument.","Fill absent optional streams with empty default sources.","Verify initialization of the component producing the fourteenth stream.","Refactor to staged CombineLatest calls (e.g. combine in groups of 4) for maintainability."],"exampleFix":"// before\nCombineLatest(s1,...,s13, fourteenth, sel); // fourteenth == null\n// after\nfourteenth ??= provider.CreateQuery<T14>(Expression.Constant(Observable.Empty<T14>()));\nCombineLatest(s1,...,s13, fourteenth, sel);","handlingStrategy":"validation","validationCode":"if (s14 == null) s14 = provider.CreateQuery<T14>(Expression.Constant(Observable.Empty<T14>()));","typeGuard":"static bool IsNonNullSource<T>(IQbservable<T> s) => s != null;","tryCatchPattern":"try { CombineLatest(..., s14, ...); } catch (ArgumentNullException ex) when (ex.ParamName == \"fourteenth\") { /* rebuild with fallback fourteenth source */ }","preventionTips":["Initialize all subscription dependencies before query composition","Group sources (4 at a time) then combine results","Validate conditional source lists for nulls","Test compositions with every source populated"],"tags":["argumentnull","qbservable","combinelatest"],"backgroundTag":"null-argument","analyzedSha":"94b5d5ab912789f5abe9a72138a25bbd716fe59c","analyzedAt":"2026-09-15T02:26:24.759Z","contentChangedAt":"2026-09-15T02:26:24.759Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}