2016-12-29 1 views
0

로그가 다음과 같이 표시됩니다. github 샘플을 완전히 따랐습니다.GCM 토큰을 얻을 수 없습니다.

2016-12-30 03:11:08.585: GCM | GCM library version 1.1.4 
2016-12-30 03:11:08.669: GCM | GCM registration is not ready with auth credentials 
Could not connect to GCM: The operation couldn’t be completed. (com.google.gcm error 501.) 
af442b82bffdf3bc1c1a30189be3edd77c9fe73e0b486b1fad58bdb535a1ea85 
2016-12-30 03:11:25.255376 WeddingLah[6326:1609423] XPC connection interrupted 
Registration to GCM failed with error: Optional("The operation couldn’t be completed. (com.google.iid error 0.)") 
af442b82bffdf3bc1c1a30189be3edd77c9fe73e0b486b1fad58bdb535a1ea85 
Registration to GCM failed with error: Optional("The operation couldn’t be completed. (com.google.iid error 0.)") 

것들 내가 시도 : 재생성 인증서

수동 개발팀을 지정하고

sanboxOption = 사실

사람이 어떤 생각을 갖고 프로필?

내 알림을 올바르게 등록했음을 보여주기 위해 내 장치 토큰을 기록에 포함 시켰습니다. @ GAEfan 외에도

+0

FCM을 사용하려고하면 더 쉽고 신선합니다. –

+0

나는 그것을 이해합니다. 하지만 불행히도 이것은 프리랜서 클라이언트 프로젝트이므로 FCM 또는 GCM에 대한 의견이 없습니다 – Happiehappie

+0

도움이 되나요? http://stackoverflow.com/questions/34087706/gcm-registration-is-not-ready-with-auth -credentials-in-ios9? https://github.com/googlesamples/google-services/issues/205 – GAEfan

답변

0

링크를 권장이 SO post는 말했다 당신이 등록 토큰을받은, 또는 토큰을 새로 고치는 데 실패했다 전에 어쩌면 당신은

GCMService.sharedInstance().connectWithHandler() { error in if(error != nil) { print(error) } } 

을 요구하고있다. refreshing your registration token을 시도해보고 제대로 작동하는지 확인하십시오.

이 항목은 thread에서도 확인할 수 있습니다.

관련 문제