You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We currently allow the TestScheduler (or anyone who wants to fiddle with the delegate for timeoutProvider) to allow config.onUnhandledError and config.onStoppedNotification to synchronously dispatch. The problem with that is if either of those throw while synchronous, it will unwind the stack and cause all sorts of crazy stuff. The provider delegates are meant primarily so that TestScheduler can synchronously control what is going on with observable emissions. onUnhandledError and onStoppedNotification are firmly outside of that lifecycle and should always be dispatched in their own call stack to prevent issues.
The text was updated successfully, but these errors were encountered:
benlesh
added a commit
to benlesh/rxjs
that referenced
this issue
Sep 20, 2023
We currently allow the TestScheduler (or anyone who wants to fiddle with the delegate for
timeoutProvider
) to allowconfig.onUnhandledError
andconfig.onStoppedNotification
to synchronously dispatch. The problem with that is if either of those throw while synchronous, it will unwind the stack and cause all sorts of crazy stuff. The provider delegates are meant primarily so that TestScheduler can synchronously control what is going on with observable emissions.onUnhandledError
andonStoppedNotification
are firmly outside of that lifecycle and should always be dispatched in their own call stack to prevent issues.The text was updated successfully, but these errors were encountered: