Post

Replies

Boosts

Views

Activity

Reply to Error on launch of app. First seen in iOS 15. What is this?
First of all NSKeyedUnarchiver should be allocated and initialized like this (objective-c): NSError* err; NSKeyedUnarchiver* unarchiver = [[NSKeyedUnarchiver alloc] initForReadingFromData:someData error:&err]; It looks like you use NSSecure coding. Therefore you have to specify classes on decoding objects. In your case it looks something like this like this NSDictionary* someDict = [unarchiver decodeObjectOfClass:[NSDictionary class] forKey:NSKeyedArchiveRootObjectKey]; But the NSDictionary contained additional strings. That was the cause of the log message. By adding NSString to the decoded class list the error is gone. NSDictionary* someDict = [unarchiver decodeObjectOfClasses:[[NSSet alloc] initWithArray:@[[NSDictionary class],[NSString class]]] forKey:NSKeyedArchiveRootObjectKey] This is a copy from my answer here: https://stackoverflow.com/questions/70050018/error-general-nskeyedunarchiver-validateallowedclassforkey-allowed-u Edit: It's well known that there was an old version of firebase/crashlytics (around 2016) that had this bug, so updating should just be it.
Nov ’21