{"record":{"id":"e705e0362f9fc721","repo":"dotnet/reactive","slug":"eighth","errorCode":null,"errorMessage":"eighth","messagePattern":"eighth","errorType":"exception","errorClass":"ArgumentNullException","httpStatus":null,"severity":"error","filePath":"Rx.NET/Source/src/System.Reactive/Linq/QbservableEx.Homoicon.cs","lineNumber":298,"sourceCode":"        /// <paramref name=\"first\" /> or <paramref name=\"second\" /> or <paramref name=\"third\" /> or <paramref name=\"fourth\" /> or <paramref name=\"fifth\" /> or <paramref name=\"sixth\" /> or <paramref name=\"seventh\" /> or <paramref name=\"eighth\" /> is null.</exception>\n        public static IQbservable<(TFirst First, TSecond Second, TThird Third, TFourth Fourth, TFifth Fifth, TSixth Sixth, TSeventh Seventh, TEighth Eighth)> CombineLatest<TFirst, TSecond, TThird, TFourth, TFifth, TSixth, TSeventh, TEighth>(this IQbservable<TFirst> first, IObservable<TSecond> second, IObservable<TThird> third, IObservable<TFourth> fourth, IObservable<TFifth> fifth, IObservable<TSixth> sixth, IObservable<TSeventh> seventh, IObservable<TEighth> eighth)\n        {\n            if (first == null)\n                throw new ArgumentNullException(nameof(first));\n            if (second == null)\n                throw new ArgumentNullException(nameof(second));\n            if (third == null)\n                throw new ArgumentNullException(nameof(third));\n            if (fourth == null)\n                throw new ArgumentNullException(nameof(fourth));\n            if (fifth == null)\n                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\n            return first.Provider.CreateQuery<(TFirst First, TSecond Second, TThird Third, TFourth Fourth, TFifth Fifth, TSixth Sixth, TSeventh Seventh, TEighth Eighth)>(\n                Expression.Call(\n                    null,\n                    new Func<IQbservable<TFirst>, IObservable<TSecond>, IObservable<TThird>, IObservable<TFourth>, IObservable<TFifth>, IObservable<TSixth>, IObservable<TSeventh>, IObservable<TEighth>, IQbservable<(TFirst First, TSecond Second, TThird Third, TFourth Fourth, TFifth Fifth, TSixth Sixth, TSeventh Seventh, TEighth Eighth)>>(CombineLatest<TFirst, TSecond, TThird, TFourth, TFifth, TSixth, TSeventh, TEighth>).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                )\n            );\n        }\n\n        /// <summary>","sourceCodeStart":280,"sourceCodeEnd":316,"githubUrl":"https://github.com/dotnet/reactive/blob/94b5d5ab912789f5abe9a72138a25bbd716fe59c/Rx.NET/Source/src/System.Reactive/Linq/QbservableEx.Homoicon.cs#L280-L316","documentation":"This ArgumentNullException is thrown by the Qbservable.CombineLatest 8-source overload when the eighth source sequence (eighth) is null. Qbservable.CombineLatest builds an expression tree for the remote/provider query, so every source must be a real observable; a null source would make the Expression.Call tree invalid. The library eagerly validates all arguments synchronously before creating the query.","triggerScenarios":"Calling QbservableEx.CombineLatest(first, second, third, fourth, fifth, sixth, seventh, eighth) on an IQbservable<TFirst> provider with eighth passed as a null IObservable<TEighth>, e.g. when the eighth sequence comes from a method, dictionary lookup, or conditional expression that returned null.","commonSituations":"Common when one source is built from a factory or config that can return null (e.g. a sensor stream that failed to initialize), when refactoring added a new source argument and left it unfilled, or when combining sequences stored in an array/collection where one slot was never populated.","solutions":["Pass a valid non-null IObservable<TEighth> as the eighth argument","If the eighth source may legitimately be absent, substitute Observable.Empty<TEighth>() or a default sequence instead of null","Check the producer of the eighth sequence (factory/lookup) to find why it returned null","Catch ArgumentNullException and report which argument (ParamName == \"eighth\") was null for diagnostics"],"exampleFix":"// before\nvar q = Observable.CombineLatest(q1, o2, o3, o4, o5, o6, o7, GetEighthStream()); // GetEighthStream() returned null\n// after\nvar eighth = GetEighthStream() ?? Observable.Empty<EighthType>();\nvar q = Observable.CombineLatest(q1, o2, o3, o4, o5, o6, o7, eighth);","handlingStrategy":"validation","validationCode":"if (q1 is null || o2 is null || o3 is null || o4 is null || o5 is null || o6 is null || o7 is null || eighth is null)\n    throw new ArgumentException(\"All CombineLatest sources must be non-null\");","typeGuard":"static bool IsNonNullSource<T>(IObservable<T>? s) => s is not null;","tryCatchPattern":"try\n{\n    var q = q1.CombineLatest(o2, o3, o4, o5, o6, o7, eighth);\n}\ncatch (ArgumentNullException ex) when (ex.ParamName == \"eighth\")\n{\n    logger.LogError(ex, \"eighth source of CombineLatest is null\");\n}","preventionTips":["Never return null from stream factories; return Observable.Empty<T>() instead","Use ?? Observable.Empty<T>() at every source-expression boundary","Null-check all sources in a helper before composing multi-source queries","Enable nullable reference types (<Nullable>enable</Nullable>) so null sources are caught at compile time"],"tags":["csharp","rx","argument-null","reactive-extensions"],"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"}