When loading some ajax via the PebbleKit JavaScript framework the app crashes, I can see via console.log() that the XMLHttpRequest.open() is called ok, but it doesn't get pass XMLHttpRequest.send().
I have had previous similar code working fine, but I have been unable to debug this issue.
It does not fire the onload event, nor timeout (at not that I can tell via console.log().
All I see in the pebble console is:
[ERROR ] Lost connection to Pebble
Looking at the composed url it does not appear to be malformed, and it loads ok in a desktop browser.
I can see via the iOS console (in xcode organiser), the error:
PebbleApp[211] : * Terminating app due to uncaught exception
'NSInvalidArgumentException', reason: '* -[NSURL
URLByAppendingPathComponent:]: component, components, or pathExtension
cannot be nil.'
Digging deeper in I can see that one of the querystring elements simply had a space at the end. Removing the space solved the problem, so I can assume that it was due to it not being properly URLEncoded.
I would of thought that this would typically be handled fine by JavaScript running in mobile webkit, but I'm guessing as it's embedded into an app, it is stricter and threw a exception.
Notably this is in beta 2 of the 2.0 sdk, so it may already be easier to diagnose in later versions.
Related
I have developed an Android app using react native.
When I run on simulator its fine, and also when I debug via USB on real device its fine.
However when I publish to Google Play store and download the app as a regular customer it sometimes crashes.
Are there any logs somewhere that I can refer to in order to identify what the issue is? Or perhaps there is something I can add to code to help identify where/why issue is occuring.
You can use log errors to do so, record the activity of user. When the app crashes, your app can ask the user to send the bug report.
Using that bug report you can understand why your app crashes.
You could also use tools like Sentry or Firebase Crashlytics with an Error Boundary
wrapping your app to report errors, allowing you to have a better understanding of the production errors by displaying the full error stack trace and a lot more.
Hello I'm using neodynamic weblientprint to print directly from browser. There's a part that includes a script that detects if the client utility is installed, after which its retrives the printers installed on the system.
However I intermittently get this error when the script runs - Unable to launch 'webclientprintvi: -getPrinters: because a user gesture is required.
I get this error on some client system browsers, while some client systems browsers never show this error. Is there a setting that needs to be configured on the browser. Browsers tests are chrome and edge
Thanks.
I discovered that if you are using the WCPP detection feature, then calling jsWebClientPrint.getPrinters() will produce the "...because a user gesture is required" console error. I had a page that called that method w/o the detection and it worked w/o complaining.
I didn't dive any deeper than that as to determining why the extra embedding detection causes this to happen. I just re-worked the page, calling the method instead on a Refresh button click; which, of course Chrome is then happen with.
I'm building a mobile app for both android and IOS by react-native. Now I want to sent crash report with stack trace + client's info to my server (by restful api). How can I catch error which I can not handle (make app crash).
I have checked crashlytics, but it can not send log to my server.
I would recommend crashlytics despite you mentioned it. I am using it for some time now and it works great. It is worth to mention that you won't receive any logs if your app isn't built in release mode (on android).
My application (IOS) don't work in iPad. I get this error after updating my i-pad and xcode:
home.html error:1
The second application works the first time, but the second time the application crashes and I get this message:
Received memory warning.
Message from debugger: Terminated due to memory issue.
I also get this message:
App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file.
I change Info.plist by doing the writing in here: Transport security has blocked a cleartext HTTP, but I still get the message.
All that after updating my IOS to 9.2 and xcode 7.2.1.
This is a bit of a strange bug that I haven't seen before. When loading the login page for a webapp I'm working on in Safari (Mac OS 10.8.2), the entire browser crashes and quits, with the message "safari web content quit unexpectedly". I don't think I've ever seen a site actually crash a browser before, outside of an infinite loop in javascript or something (and really, it doesn't seem like it should be possible). Is there any Apache header or something that is known to crash Safari? Any help pointing me in the right direction would be appreciated.
What I've Done:
Removed all meta tags and it still crashed.
It is getting the SSL certificate before it crashes, because I got the security warning (certificate doesn't match the url, since I'm testing locally)
It's crashing almost immediately, so I doubt that there's any javascript that's causing it
Use the process of elimination. Remove some code, test app. If it doesn't work, continue removing code until you find the cause.
In case anyone ever happens to stumble across this question, the problem ended up being using CSS3 transitions in conjunction with calc() values. Apparently having them together causes Safari to crash (before the transition is even triggered, I might add). I solved it by doing some simple browser detection to add a class to the body when the browser was anything but Safari, and only do the transitions related to calc() values on elements inside that class.