Question

I have a prolem when i used facebook sdk for unity when login on android (real device - Gooogle nexus 7 2012). - adb logcat this error: W/fb4a(:):BlueServiceQueue(10494): Exception during service W/fb4a(:):BlueServiceQueue(10494): com.facebook.http.protocol.ApiException: Key hash rhDpGcyTNP33kRZOYIKdOcoevoM does not match any stored key hashes. W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.protocol.ApiResponseChecker.b(ApiResponseChecker.java:83) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.protocol.ApiResponseChecker.a(ApiResponseChecker.java:162) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.protocol.ApiResponse.h(ApiResponse.java:239) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.katana.server.protocol.AuthorizeAppMethod.a(AuthorizeAppMethod.java:272) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.katana.server.protocol.AuthorizeAppMethod.a(AuthorizeAppMethod.java:29) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.protocol.ApiResponseHandler.a(ApiResponseHandler.java:59) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.protocol.ApiResponseHandler.handleResponse(ApiResponseHandler.java:29) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.common.FbHttpRequestProcessor.a(FbHttpRequestProcessor.java:363) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.common.FbHttpRequestProcessor.a(FbHttpRequestProcessor.java:179) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.common.FbHttpRequestProcessor.b(FbHttpRequestProcessor.java:139) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.common.FbHttpRequestProcessor.a(FbHttpRequestProcessor.java:237) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.protocol.SingleMethodRunnerImpl.a(SingleMethodRunnerImpl.java:378) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.protocol.SingleMethodRunnerImpl.a(SingleMethodRunnerImpl.java:156) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.http.protocol.AbstractSingleMethodRunner.a(AbstractSingleMethodRunner.java:16) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.katana.server.handler.PlatformOperationHandler.c(PlatformOperationHandler.java:366) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.katana.server.handler.PlatformOperationHandler.a(PlatformOperationHandler.java:259) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.fbservice.service.BlueServiceQueue.e(BlueServiceQueue.java:299) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.fbservice.service.BlueServiceQueue.d(BlueServiceQueue.java:53) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.fbservice.service.BlueServiceQueue$3.run(BlueServiceQueue.java:230) W/fb4a(:):BlueServiceQueue(10494): at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:390) W/fb4a(:):BlueServiceQueue(10494): at java.util.concurrent.FutureTask.run(FutureTask.java:234) W/fb4a(:):BlueServiceQueue(10494): at com.facebook.common.executors.ListenableScheduledFutureImpl.run(ListenableScheduledFutureImpl.java:59) W/fb4a(:):BlueServiceQueue(10494): at android.os.Handler.handleCallback(Handler.java:725) W/fb4a(:):BlueServiceQueue(10494): at android.os.Handler.dispatchMessage(Handler.java:92) W/fb4a(:):BlueServiceQueue(10494): at android.os.Looper.loop(Looper.java:137) W/fb4a(:):BlueServiceQueue(10494): at android.os.HandlerThread.run(HandlerThread.java:60) W/Bundle (12430): Key com.facebook.platform.protocol.PROTOCOL_VERSION expected String but value was a java.lang.Integer. The default value was returned. W/Bundle (12430): Attempt to cast generated internal exception: W/Bundle (12430): java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String

..... .... V/FBUnitySDK(21692): sending to Unity OnLoginComplete({"cancelled":true}) I/Unity (21692): call login: I/Unity (21692): I/Unity (21692): (Filename: ./Runtime/ExportGenerated/AndroidManaged/UnityEngineDebug.cpp Line: 54) I/Unity (21692): I/Unity (21692): login result: {"is_logged_in":false,"user_id":"","access_token":""} I/Unity (21692): I/Unity (21692): (Filename: ./Runtime/ExportGenerated/AndroidManaged/UnityEngineDebug.cpp Line: 54)

  • When i uninstall facebook app, this app working fine.
  • I think this error occur because my key hash. Please help me out this problem. (Sorry my english not good)
Était-ce utile?

La solution

The key hash you're passing to the Facebook SDK isn't stored with your developer account.

W/fb4a(:):BlueServiceQueue(10494): com.facebook.http.protocol.ApiException: Key hash rhDpGcyTNP33kRZOYIKdOcoevoM does not match any stored key hashes. 

Go to developers.facebook.com/apps/ and add it in the android section (key hash rhDpGcyTNP33kRZOYIKdOcoevoM)

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top