由于Spotify问题,应用程序在启动时崩溃

时间:2013-11-01 09:36:47

标签: ios iphone spotify cocoalibspotify-2.0

我们正在开发一个项目,我们从Spotify获取Feed。我们已将Spotify库集成在一起。由于应用程序启动崩溃问题,该应用程序被MFI审批流程拒绝。我们被困在这里。它非常紧急,我们非常感谢您的帮助。

我们在应用启动时收到应用崩溃错误。我们正在调用一种方法,这可能是崩溃的原因,但我们不确定。

- (void)clearKeychain {
  for( NSString *serviceName in @[@"rdio",@"spotify",@"spotifyUsername",@"muzik"]) {
    DDLogVerbose(@"removing keychain entry for service = %@", serviceName);
    [MZUserManager removeTokenForService:serviceName];
  }

MZSpotifyService *spotify = (MZSpotifyService*)[[MZDataManager sharedManager] serviceWithName:[MZSpotifyService shortName]];
  [spotify.sessionManager logout];

  [MZRdioService rdio].delegate = nil;
  [[MZRdioService rdio] logout];
}

---------------------------------

- (MZBaseService *)serviceWithName:(NSString *)serviceName
{
    NSLog(@"active services : \n %@",_activeServices);
  return _activeServices[serviceName];
}

---------------------------------------

- (void)logout {
  [[SPSession sharedSession] logout:^{
    DDLogVerbose(@"logged out from spotify");
  }];
}

以下是日志

2013-10-31 15:43:54 -0700 muzik[297] <Warning> *** Assertion failure in NSString* base::deviceIdFromKeychain()(), /Users/spotify-buildagent/buildAgent/work/1e0ce8a77adfb2dc/client/base/_apple/_ios/os_ios.mm:287
2013-10-31 15:43:54 -0700 muzik[297] <Error> *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Keychain error when fetching device ID, nonrecoverable'
*** First throw call stack:
(0x2e265e8b 0x385ca6c7 0x2e265d5d 0x2ec0e29b 0x2ea90f 0x2eaee5 0x2e7bb3 0x1a618d 0x1a545d 0x2e230f55 0x2e2302cf 0x2e22ebd5 0x2e199541 0x2e1dd1ab 0x1a55a1 0x2ec49dc7 0x38be0c5d 0x38be0bcf 0x38bdecd0)

详情日志为uploaded here(跳伞)

MFI共享的完整崩溃日志

Date/Time:           2013-10-31 15:43:54.065 -0700
OS Version:          iOS 7.0.2 (11A501)
UDID:                41ab058a88eb7c1c3976828019bdfa0bd5edae22
Report Version:      104

Exception Type:  EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Triggered by Thread:  7

Filtered syslog:
2013-10-31 15:43:52 -0700 muzik[297] <Warning> Flurry: Starting session on Agent Version [Flurry_iOS_120_4.2.4] 
2013-10-31 15:43:53 -0700 muzik[297] <Error>  SecOSStatusWith error:[-34018] The operation couldn’t be completed. (com.apple.security.osstatus error -34018 - Remote error : The operation couldn‚Äôt be completed. (com.apple.security.osstatus error -34018 - client has neither application-identifier nor keychain-access-groups entitlements))
2013-10-31 15:43:53 -0700 muzik[297] <Error>  SecOSStatusWith error:[-34018] The operation couldn’t be completed. (com.apple.security.osstatus error -34018 - Remote error : The operation couldn‚Äôt be completed. (com.apple.security.osstatus error -34018 - client has neither application-identifier nor keychain-access-groups entitlements))
2013-10-31 15:43:53 -0700 muzik[297] <Error>  SecOSStatusWith error:[-34018] The operation couldn’t be completed. (com.apple.security.osstatus error -34018 - Remote error : The operation couldn‚Äôt be completed. (com.apple.security.osstatus error -34018 - client has neither application-identifier nor keychain-access-groups entitlements))
2013-10-31 15:43:53 -0700 muzik[297] <Error>  SecOSStatusWith error:[-34018] The operation couldn’t be completed. (com.apple.security.osstatus error -34018 - Remote error : The operation couldn‚Äôt be completed. (com.apple.security.osstatus error -34018 - client has neither application-identifier nor keychain-access-groups entitlements))
2013-10-31 15:43:53 -0700 muzik[297] <Error>  SecOSStatusWith error:[-34018] The operation couldn’t be completed. (com.apple.security.osstatus error -34018 - Remote error : The operation couldn‚Äôt be completed. (com.apple.security.osstatus error -34018 - client has neither application-identifier nor keychain-access-groups entitlements))
2013-10-31 15:43:53 -0700 muzik[297] <Error>  SecOSStatusWith error:[-34018] The operation couldn’t be completed. (com.apple.security.osstatus error -34018 - Remote error : The operation couldn‚Äôt be completed. (com.apple.security.osstatus error -34018 - client has neither application-identifier nor keychain-access-groups entitlements))
2013-10-31 15:43:53 -0700 muzik[297] <Error>  SecOSStatusWith error:[-34018] The operation couldn’t be completed. (com.apple.security.osstatus error -34018 - Remote error : The operation couldn‚Äôt be completed. (com.apple.security.osstatus error -34018 - client has neither application-identifier nor keychain-access-groups entitlements))
2013-10-31 15:43:54 -0700 muzik[297] <Error>  SecOSStatusWith error:[-34018] The operation couldn’t be completed. (com.apple.security.osstatus error -34018 - Remote error : The operation couldn‚Äôt be completed. (com.apple.security.osstatus error -34018 - client has neither application-identifier nor keychain-access-groups entitlements))
2013-10-31 15:43:54 -0700 muzik[297] <Error>  SecOSStatusWith error:[-34018] The operation couldn’t be completed. (com.apple.security.osstatus error -34018 - Remote error : The operation couldn‚Äôt be completed. (com.apple.security.osstatus error -34018 - client has neither application-identifier nor keychain-access-groups entitlements))
2013-10-31 15:43:54 -0700 muzik[297] <Warning> *** Assertion failure in NSString* base::deviceIdFromKeychain()(), /Users/spotify-buildagent/buildAgent/work/1e0ce8a77adfb2dc/client/base/_apple/_ios/os_ios.mm:287
2013-10-31 15:43:54 -0700 muzik[297] <Error> *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Keychain error when fetching device ID, nonrecoverable'
*** First throw call stack:
(0x2e265e8b 0x385ca6c7 0x2e265d5d 0x2ec0e29b 0x2ea90f 0x2eaee5 0x2e7bb3 0x1a618d 0x1a545d 0x2e230f55 0x2e2302cf 0x2e22ebd5 0x2e199541 0x2e1dd1ab 0x1a55a1 0x2ec49dc7 0x38be0c5d 0x38be0bcf 0x38bdecd0)

1 个答案:

答案 0 :(得分:2)

重要的错误在于:

  

无法完成操作。 (OSStatus错误-34018 - 客户端既没有应用程序标识符也没有keychain-access-groups权利)

现在,至于你为什么要触发它,我不知道。尝试使用Google搜索特定错误 - 它不是Spotify特定的。

但是,您似乎将Keyify凭据存储在钥匙串中,并且您可能通过从钥匙串中清除内容来触发问题。不幸的是,&#34;我们正在调用一种方法&#34;不是有用的信息。

现在,您不应该将Spotify凭据存储在钥匙串中。绝对不是用户密码 - 这是对ToS的破坏。 CocoaLibSpotify为您提供可以安全存储在NSUserDefaults

中的令牌

您可以在&#34;空CocoaLibSpotify&#34;中找到如何正确存储Spotify凭据的示例。随库提供的示例项目。

此外,尝试在将存档构建提交到App Store之前对其进行测试。如果在审核过程中发生这种情况,那么就没有理由不在本地触发你。

相关问题