I am having an issue when instantiating my CBCentralManager. I get a "duplicate issue" message when monitoring it from the iOS console (it does not show in the XCode console).
I've tried updating the queue name and the restoration key id without success. This is how I instantiate my Central Manager:
CBCentralManager *central = [[CBCentralManager alloc] initWithDelegate: self
queue: dispatch_queue_create("com.mydomain.myapp.scanner", NULL)
options: @{
CBCentralManagerOptionRestoreIdentifierKey: @"hexa-string-comes-here"
}];
And those are the errors I am getting:
CKLs-iPhone-5S securityd[78] : securityd_xpc_dictionary_handler MyApp[2571] add The operation couldn’t be completed. (OSStatus error -25299 - duplicate item O,genp,E99372E2,L,ck,X2W6M5UYJ9.com.mydomain.myapp,0,acct,svce,v_Data,20151218165347.298588Z,2CAE5650)
CKLs-iPhone-5S MyApp[2571] : SecOSStatusWith error:[-25299] The operation couldn’t be completed. (OSStatus error -25299 - Remote error : The operation couldn‚Äôt be completed. (OSStatus error -25299 - duplicate item O,genp,E99372E2,L,ck,X2W6M5UYJ9.com.mydomain.myapp,0,acct,svce,v_Data,20151218165347.298588Z,2CAE5650))
Any ideas?
If you want to use the CBCentralManagerOptionRestoreIdentifierKey
, you must
implement the method
// in Objective-C
- (void)centralManager:(CBCentralManager *)central willRestoreState:(NSDictionary<NSString *, id> *)dict
// or in Swift
func centralManager(_ central: CBCentralManager, willRestoreState dict: [String : AnyObject])
from CBCentralManagerDelegate
, and
use the background mode Uses Bluetooth LE accessories set up in Xcode:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With