App crashes with BLE under Swift - ios

I am developing a Swift App using Bluetooth LE, that crashes from time to time - not really reproducable.
I get always the same error message but can't find anything to lighten things up.
*** Assertion failure in -[CBUUID initWithData:], /BuildRoot/Library/Caches/com.apple.xbs/Sources/CoreBluetooth/CoreBluetooth-327.1/CBUUID.m:170
*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Data <> does not
represent a valid UUID'
Does anybody has a idea what the error might be?
Thanks in advance
Reto

Related

Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'FCM error: cannot have last checkin timestamp in future'

As every app these days have firebase push notifications, so do our app. Everything works fine like sending notifications and all. But I started getting this error :
Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'FCM error: cannot have last checkin timestamp in future'
logs for above error:
2019-03-26 15:27:49.375300+0530 appName[665:131254] * Assertion failure in -FIRInstanceIDCheckinPreferences hasValidCheckinInfo, /Users/username/Desktop/appName/Pods/FirebaseInstanceID/Firebase/InstanceID/FIRInstanceIDCheckinPreferences.m:66
2019-03-26 15:27:49.379038+0530 appName[665:131254] * Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'FCM error: cannot have last checkin timestamp in future'
Cause of error: User changes the device time to a date and time before the last checkin timestamp.
Firebase SDK version used is 5.19.0
If user sets the device time to automatic, this error does not occur.
I'm not able to catch this exception as this is occurring even before didFinishLaunchingWithOptions
Any help regarding handling this issue is appreciated.
I am observing this crash if Device date is changed
You need to have an exception handler at the entry point of you application. Read this post: What is the entry point of swift code execution? to understand what is the entry point of your iOS app.
As pointed out in the comments, this is a development mode only assertion and should not occur in release mode.
See the implementation here.
This happens when you set device's date to something in the past.

There doesn't seem to be a valid compiled storyboard at path in xcode 7.3 on ios9.3

I'm writing application(iPad only app) for iPad(running iOS 9.3.3) its working well, but sometimes it get crashed by throwing,
2016-10-18 16:09:14.129 appName[239:23575] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'There doesn't seem to be a valid compiled storyboard at path '/var/containers/Bundle/Application/78FAE276-6B37-4A64-AB82-21F171D8E383/appName.app/PDSuperStory.storyboardc''
*** First throw call stack:
(0x2149f91b 0x20c3ae17 0x2611ff71 0x84a88 0x13ef90 0xa6150 0x10c4dc 0x145a58 0xbd1b7f 0xbd1b6b 0xbd6655 0x21461b6d 0x21460067 0x213af229 0x213af015 0x2299fac9 0x25a83189 0x111698 0x21057873)
libc++abi.dylib: terminating with uncaught exception of type NSException
Before this crash everything works fine no memory leaks showing in Instruments either. No solution working out after cleaning the project or re-installing application on device.
Any solution guys?
I was getting the same error till I just did Product>Clean Build Folder and now it seems all good.

'NSInternalInconsistencyException', reason: 'Unrecognized database version: ' Firebase crash on physical device

My app keeps crashing on physical device, but it works on simulator. and I can't find any information on that bug. I am using firebase. My app has been working fine for a while and this randomly occurs.
2016-08-08 14:50:14.081 gameofchats[1626:570752] * Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Unrecognized database version: '
* First throw call stack:
(0x182462db0 0x181ac7f80 0x182462cf8 0x1001b1bc8 0x1001b1ab0 0x1001c2a84 0x100ed5a7c 0x100ed5a3c 0x100ee2554 0x100ed972c 0x100ee466c 0x100ee4364 0x1820c5470 0x1820c5020)
libc++abi.dylib: terminating with uncaught exception of type NSException
I've faced more or less the same issue.
I remove the app from my device and let xCode install a fresh copy of it and that solved the issue.
My guess is that somehow the local Firebase cache must have been corrupted and each time Firebase's sdk tried to access it the app crashs.

Glympse Lite API Dismiss Button crash

I am trying to incorporate the Glympse Lite iOS SDK v1.0.12 into my app.
But I have a problem.
Trying to Dismiss "Sending.." screen causes the application to crash.
Tried to use solution from here https://stackoverflow.com/a/17889940/3805275 but still get the crash.
Try to do the same with the sample project GlympseHistoryLiteDemo and also get crash with the following output:
-[GLYConfiguratorViewerOwner onDismissPleaseWait:]: unrecognized selector sent to instance 0x15daa5c0
TICKET_CHANGED FIRED
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason:
'-[GLYConfiguratorViewerOwner onDismissPleaseWait:]: unrecognized selector sent to instance 0x15daa5c0'
*** First throw call stack:
(0x2e1d0f4b ...) libc++abi.dylib: terminating with uncaught exception of type NSException
Any ideas what might be causing this crash and possible solution ?
Btw, I was testing on iPod Touch with iOS 7.0.4.

UITableView _endCellAnimationsWithContext: assertion failure without reason

I'm using a UITableView to display some settings to the user. When reloading a section or inserting some rows with animation, it is possible to make a mistake in the the delegate/datasource functions causing an
Assertion failure in -[UITableView _endCellAnimationsWithContext:], /SourceCache/UIKit/UIKit-3232.3/UITableView.m:1560
This has happened to me many times, but usually it also states what I did wrong, like so:
Assertion failure in -[UITableView _endCellAnimationsWithContext:],
/SourceCache/UIKit/UIKit-2380.17/UITableView.m:1070
Terminating app due to uncaught exception
'NSInternalInconsistencyException', reason: 'Invalid update: invalid
number of rows in section 0.
As of late, the reason is not displayed in the console anymore, just the assertion failure and a SIGABRT line.
This is very annoying and makes debugging very time consuming. Any clue what I can do to restore this feature?
After posting my question and re-reading it, I realised that the portion of the message I was missing was the part of the uncaught exception
Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Invalid update: invalid number of rows in section 0.
I then realised I am using the PLCrashReporter since a month or two to report uncaught exceptions to our server. Disabling the crashreporter restored the reason bit of the message in the console.
doh!

Resources