Skip to content

fix(useDeprecatedSynchronousErrorHandling): now throws properly when notifying a Subject#6472

Closed
benlesh wants to merge 1 commit intoReactiveX:masterfrom
benlesh:fix/6471-super-gross-subject-next
Closed

fix(useDeprecatedSynchronousErrorHandling): now throws properly when notifying a Subject#6472
benlesh wants to merge 1 commit intoReactiveX:masterfrom
benlesh:fix/6471-super-gross-subject-next

Conversation

@benlesh
Copy link
Member

@benlesh benlesh commented Jun 11, 2021

Resolves #6471

@benlesh benlesh requested a review from cartant June 11, 2021 20:02
@benlesh
Copy link
Member Author

benlesh commented Jun 11, 2021

cc @leggechr

*/
error(err?: any): void {
if (this.isStopped) {
if (this.isStopped && !config.useDeprecatedSynchronousErrorHandling) {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@leggechr this is the fix.

Copy link
Collaborator

@cartant cartant Jun 11, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Surely this is going to cause other problems? This renders stopped meaningless for error notifications if that config is used? How did this ever work in v6? If it didn't, should we really change this? FWIW, I don't particularly care - the sooner this configuration setting is removed, the better, IMO - but I thought I'd point it out.


export declare const observable: string | symbol;
export declare const observable: string | typeof Symbol.observable;

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why has this changed? The last time this happened, IIRC, it was in that PR that sought to bump to TS 4.3. Are you sure you have 4.2 installed?

*/
error(err?: any): void {
if (this.isStopped) {
if (this.isStopped && !config.useDeprecatedSynchronousErrorHandling) {
Copy link
Collaborator

@cartant cartant Jun 11, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Surely this is going to cause other problems? This renders stopped meaningless for error notifications if that config is used? How did this ever work in v6? If it didn't, should we really change this? FWIW, I don't particularly care - the sooner this configuration setting is removed, the better, IMO - but I thought I'd point it out.

Copy link
Collaborator

@cartant cartant left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, the api_guardian thing needs to be addressed.

@leggechr
Copy link
Contributor

This caused tons more failing tests in google. The error is: TypeError: Cannot read property 'error' of null at this line: https://github.com/ReactiveX/rxjs/blob/master/src/internal/Subscriber.ts#L123

@benlesh benlesh force-pushed the fix/6471-super-gross-subject-next branch from 69aea0b to bb1b637 Compare June 16, 2021 23:15
@benlesh
Copy link
Member Author

benlesh commented Jun 16, 2021

Completely redone... very hacky for now... only one issue left though (marked with it.skip in the tests). cc @cartant @leggechr

@benlesh
Copy link
Member Author

benlesh commented Jun 17, 2021

Closing in favor of #6478

@benlesh benlesh closed this Jun 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Super Gross Mode @ Google: Subjects no longer throw while nexting

3 participants