NullReferenceException on Stream Client when Calling OnCompletedAsync
When a Stream client calls OnCompletedAsync I get a NullReferenceException. A minimal repro is provided in the attached zip
OrleansSample.zip
The problem is in these lines: https://github.com/dotnet/orleans/blob/f643b16e80725389e42d85ec22e533b530f3b8a5/src/Orleans.Core/Streams/Internal/StreamImpl.cs#L106-L107
Here producerInterface is of type SimpleMessageStreamProducer and this type does not inherit from IAsyncBatchObserver<T>.
https://github.com/dotnet/orleans/blob/f12e488184b326408ae40098249c7dd873081d7b/src/Orleans.Core/Streams/SimpleMessageStream/SimpleMessageStreamProducer.cs#L12
https://github.com/dotnet/orleans/blob/f643b16e80725389e42d85ec22e533b530f3b8a5/src/Orleans.Core/Streams/Internal/IInternalAsyncObservable.cs#L26
https://github.com/dotnet/orleans/blob/f643b16e80725389e42d85ec22e533b530f3b8a5/src/Orleans.Core.Abstractions/Streams/Core/IAsyncBatchProducer.cs#L13
https://github.com/dotnet/orleans/blob/f643b16e80725389e42d85ec22e533b530f3b8a5/src/Orleans.Core.Abstractions/Streams/Core/IAsyncObserver.cs#L14
Looks like this is being fixed by #5769. Thanks @sergeybykov