
Close #31684. In some rxjs operator, such as `retryWhen`, rxjs internally will set `Subscription._unsubscribe` method to null, and the current zone.js monkey patch didn't handle this case correctly, even rxjs set _unsubscribe to null, zone.js still return a function by finding the prototype chain. This PR fix this issue and the following test will pass. ``` const errorGenerator = () => { return throwError(new Error('error emit')); }; const genericRetryStrategy = (finalizer: () => void) => (attempts: Observable<any>) => attempts.pipe( mergeMap((error, i) => { const retryAttempt = i + 1; if (retryAttempt > 3) { return throwError(error); } return timer(retryAttempt * 1); }), finalize(() => finalizer())); errorGenerator() .pipe( retryWhen(genericRetryStrategy(() => { expect(log.length).toBe(3); done(); })), catchError(error => of(error))) .subscribe() ``` PR Close #37091
Angular
Angular es una plataforma de desarrollo para construir aplicaciones web y móviles que usa TypeScript/JavaScript y otros lenguajes de programación.
Guía rápida
Comienza a usarlo en 5 minutos.
Registro de cambios (Changelog)
¿Quieres ayudar?
¿Quieres encontrar fallos, colaborar con código, o mejorar la documentación? ¡Excelente! Lee nuestras pautas para colaborar y luego revisa algunos de nuestras incidencias (issues) en ayuda comunitaria.
Description
Languages
TypeScript
86.3%
JavaScript
8.5%
HTML
1.8%
Starlark
1.7%
CSS
1%
Other
0.6%