简体   繁体   English

facebook 在模拟器上工作,而不是在设备上

[英]facebook working on emulator not on device

Its working perfectly on emulator but not on device.它可以在模拟器上完美运行,但不能在设备上运行。
crashing at response = read(conn.getInputStream()); response = read(conn.getInputStream());崩溃response = read(conn.getInputStream()); in facebook sdk.在 facebook sdk 中。

Yeah I had this issue,是的,我有这个问题,

It worked fine on the emulator, worked fine on my dev phone, but failed on the test users phone.它在模拟器上运行良好,在我的开发手机上运行良好,但在测试用户手机上运行失败。

It's to do with the Facebook app and SSO.这与 Facebook 应用程序和 SSO 有关。

Have a read of this : http://sean.lyn.ch/2011/07/android-the-facebook-sdk-sso-and-you/阅读一下: http : //sean.lyn.ch/2011/07/android-the-facebook-sdk-sso-and-you/

It has 3 solutions.它有3个解决方案。

I couldn't get SSO to work so I went for option two, (opt out of SSO!) This is done by:我无法让 SSO 工作,所以我选择了选项二,(选择退出 SSO!)这是通过以下方式完成的:

facebook.authorize(this, PERMISSIONS, Facebook.FORCE_DIALOG_AUTH, this); facebook.authorize(this, PERMISSIONS, Facebook.FORCE_DIALOG_AUTH, this); If you want to fix it and get SSO to work:如果您想修复它并使 SSO 工作:

Correctly generate your hash key for the debug apk certificate.正确生成调试 apk 证书的哈希密钥。 (detailed in the link above). (在上面的链接中有详细说明)。

Ref:参考:

https://stackoverflow.com/a/7158056/1838457 https://stackoverflow.com/a/7158056/1838457

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Facebook集成可以在模拟器中运行,但不能在Android设备中运行吗? - Facebook integration working in emulator but not working in android device? Facebook身份验证在仿真器上工作,但不在物理设备上 - Facebook Authentication working on Emulator, But not on physical device Facebook图像共享可在模拟器中运行,但不能在设备中运行 - Facebook image sharing working in emulator but not in device Facebook无法在Android设备上登录,但可以在Android Studio模拟器中使用 - Facebook log in on Android device not working, but works in Android Studio Emulator 动画只能在模拟器上运行,而不能在设备上运行 - Animations working on emulator but not on device MediaPlayer在模拟器上运行,但不在设备上运行 - MediaPlayer working on emulator, but not on device 在设备上也不在模拟器上不起作用 - not working on device and not on emulator alignParentBottom 在模拟器中工作但不在设备上 - alignParentBottom working in emulator but not on device 广播接收器在模拟器中工作,但不在设备中工作 - Broadcastreceiver working in emulator but not in device 在设备/模拟器上安装Facebook应用程序时,用户Facebook墙不能正常工作 - Post to user facebook wall not working when Facebook app is installed on device/emulator
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM