trace.write("UIWebViewDelegateClass.webViewDidStartLoad(" + webView.request.URL + ")", trace.categories.Debug);
IOS
This is related only to tns-core-modules: The version affected is 2.2.1 but it doesn't seams to be fixed on the latest tns-core
I have no idea how to reproduce the issue because is coming form our app on the store. I can not know what the end user is clicking. Just make sure that webView.request is something before trying to access URL
"2": "TypeError: null is not an object (evaluating 'webView.request.URL') ",
"3": "",
"4": " stackTrace:",
"5": " webViewDidStartLoad@file:///app/tns_modules/ui/web-view/web-view.js:44:88",
"6": "UIApplicationMain@[native code]",
"7": "start@file:///app/tns_modules/application/application.js:233:26",
"8": "anonymous@file:///app/app.js:154:18",
"9": "evaluate@[native code]",
"10": "moduleEvaluation@[native code]",
"11": "[native code]",
"12": "promiseReactionJob@[native code]"
Submitted a PR for a fix for this: https://github.com/NativeScript/NativeScript/pull/4830
@AntonioCuevaUrraco @davecoffin Could you share steps to reproduce the crash so that we can add unit-test?
Its sort of hard to reproduce, it happens with certain URLs and I'm not sure why. But my fix just in #4830 just brings it in line with how its handled in webViewDidFailLoadWithError further down in the file, it appeared to just be an oversight.
Can you share the URL that you manage to reproduce it?
Well thats just the thing, that function is being invoked with no URL, thats why its crashing:
https://cl.ly/nBaL
https://cl.ly/nCXz
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Most helpful comment
Submitted a PR for a fix for this: https://github.com/NativeScript/NativeScript/pull/4830