dotnet/reactive · error · ArgumentNullException
throw new ArgumentNullException(nameof(thirteenth))
Error message
throw new ArgumentNullException(nameof(thirteenth))
What it means
System.ArgumentNullException raised by the null-guard for the thirteenth source in a CombineLatest overload in QbservableEx.Homoicon.cs. The guard chain runs in argument order and failed at thirteenth == null before any query expression was created.
Solutions
- Assign or resolve a real thirteenth IQbservable source before the call.
- Use an empty placeholder stream for optional sources.
- Trace the thirteenth argument's producer and fix the null return.
- Add a pre-call null assertion covering every source.
Example fix
// before CombineLatest(s1,...,s12, thirteenth, sel); // thirteenth == null // after thirteenth ??= provider.CreateQuery<T13>(Expression.Constant(Observable.Empty<T13>())); CombineLatest(s1,...,s12, thirteenth, sel);
Defensive patterns
Strategy: validation
Validate before calling
if (s13 == null) throw new ArgumentException("thirteenth source must be provided", nameof(s13)); Type guard
static bool IsNonNullSource<T>(IQbservable<T> s) => s != null;
Try / catch
try { CombineLatest(..., s13, ...); } catch (ArgumentNullException ex) when (ex.ParamName == "thirteenth") { /* log missing stream, retry with default */ } Prevention
- Assign every declared stream before composing
- Fix providers that resolve null for remote sources
- Use staged combining to keep arities small
- Assert full source list before the call
When it happens
Trigger: Invoking the 13+ argument Qbservable.CombineLatest overload with thirteenth == null at line 920 of the guard chain.
Common situations: A stream added during refactoring was declared but never assigned; a remote provider source failed to resolve.
Related errors
- fifth
- fourth
- third
- throw new ArgumentNullException(nameof(eighth))
- throw new ArgumentNullException(nameof(eleventh))
AI-assisted analysis of dotnet/reactive@94b5d5ab91 (2026-09-15).
Data as JSON: /api/errors/1f0e2d19504591f4.
Report an issue: GitHub.
Appendix: source
Thrown at Rx.NET/Source/src/System.Reactive/Linq/QbservableEx.Homoicon.cs:920
throw new ArgumentNullException(nameof(fourth));
if (fifth == null)
throw new ArgumentNullException(nameof(fifth));
if (sixth == null)
throw new ArgumentNullException(nameof(sixth));
if (seventh == null)
throw new ArgumentNullException(nameof(seventh));
if (eighth == null)
throw new ArgumentNullException(nameof(eighth));
if (ninth == null)
throw new ArgumentNullException(nameof(ninth));
if (tenth == null)
throw new ArgumentNullException(nameof(tenth));
if (eleventh == null)
throw new ArgumentNullException(nameof(eleventh));
if (twelfth == null)
throw new ArgumentNullException(nameof(twelfth));
if (thirteenth == null)
throw new ArgumentNullException(nameof(thirteenth));
if (fourteenth == null)
throw new ArgumentNullException(nameof(fourteenth));
if (fifteenth == null)
throw new ArgumentNullException(nameof(fifteenth));
if (sixteenth == null)
throw new ArgumentNullException(nameof(sixteenth));
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)>(
Expression.Call(
null,
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,
first.Expression,
GetSourceExpression(second),
GetSourceExpression(third),
GetSourceExpression(fourth),
GetSourceExpression(fifth),
GetSourceExpression(sixth),
GetSourceExpression(seventh),View on GitHub (pinned to 94b5d5ab91)