Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

String: TypeError: null is not an object (evaluating 'S.onComplete') #3102

Open
vorderpneu opened this issue Jul 26, 2024 · 2 comments
Open

Comments

@vorderpneu
Copy link

We use lottie-web in an Ionic app with Angular and ngrx-lottie to display an animation. For some time now, we have been seeing the following error in our error logs:

String: TypeError: null is not an object (evaluating 'S.onComplete')
    postMessage@webpack:///node_modules/lottie-web/build/player/esm/lottie_light.min.js:424:28
    We@webpack:///node_modules/zone.js/fesm2015/zone.js:755:44
    runTask@webpack:///node_modules/zone.js/fesm2015/zone.js:173:57
    invokeTask@webpack:///node_modules/zone.js/fesm2015/zone.js:483:41
    O@webpack:///node_modules/zone.js/fesm2015/zone.js:1631:24
    N@webpack:///node_modules/zone.js/fesm2015/zone.js:1674:43

The error occurs here:

process.onComplete(data.payload);

What is the reason that process can be null, and what would be the best way to handle this error properly?

Only iPhones and MacBooks are affected. Unfortunately, we have not been able to reproduce it on our own devices.

Browsers:
Mobile Safari UI/WKWebView
Apple Mail 605.1

OS Versions:
iOS 15.6
iOS 15.7
iOS 15.8
iOS 16.3
iOS 16.7
iOS 17.5
Mac OS X 10.15

@vorderpneu
Copy link
Author

@neehhaa06 Yes, i already tried those two suggestions, but the error is still handled by the zone.js globalCallback error and that's why the angular app still doesn't know about those errors. Yes, i could override window.onerror to handle the error, but i want to avoid that.

My idea is to have an ErrorEvent similar to e.g. BMRenderFrameErrorEvent so that I can handle the Error in the Angular app

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

No branches or pull requests

2 participants
@vorderpneu and others