Facebook / Parse登录行为异常:代理的应用程序尚未安装

时间:2014-05-25 22:33:07

标签: java android facebook parse-platform facebook-login

我为此疯狂!虽然,的解决方案对我有帮助,但他们没有解决我的问题。

我正在将Facebook登录添加到我当前的应用中。踢球者是,我有几个已经有这个功能的应用程序。我没有问题添加到他们!我查看了这些应用程序的代码,我现在正在处理的代码是完全相同的。我能想到的唯一区别是这款应用已经上市然后获得了Facebook登录功能。但是,我无法想象那会很重要......

代码:

    Button fb = (Button) view.findViewById(R.id.bFacebook);
    Settings.setApplicationId(APPLICATION_ID);

    fb.setOnClickListener(new View.OnClickListener() {
        @Override
        public void onClick(View view) {
            Log.d(TAG, "BUTTON WAS PRESSED");

            ParseFacebookUtils.logIn(Arrays.asList(ParseFacebookUtils.Permissions.User.ABOUT_ME),
                    getActivity(), new LogInCallback() {
                @Override
                public void done(final ParseUser user, ParseException err) {
                    if (user == null) {
                        Log.d("MyApp", "Uh oh. The user cancelled the Facebook login.");
                        Toast.makeText(getActivity(), "CANCEL", Toast.LENGTH_LONG).show();

                    } else if (user.isNew()) {
                        Log.d("MyApp", "User signed up and logged in through Facebook!");
                        Toast.makeText(getActivity(), "SIGNUP", Toast.LENGTH_LONG).show();
                    } else {
                        Log.d("MyApp", "User logged in through Facebook!");
                        Toast.makeText(getActivity(), "LOGIN", Toast.LENGTH_LONG).show();
                    }
                    end();
                }

                private void end() {
                    activity.changeFrag(Drawer.Frag.HOME);
                }
            });
        }
    });


}

@Override
public void onActivityResult(int requestCode, int resultCode, Intent data) {
    super.onActivityResult(requestCode, resultCode, data);
    ParseFacebookUtils.finishAuthentication(requestCode, resultCode, data);
}

我收到警告:

  

com.facebook.http.protocol.ApiException:代理的应用程序尚未安装。

会发生什么:

  1. 我点击登录按钮,FB应用程序按原样打开
  2. 简要介绍一个微调器。
  3. 然后FB会立即关闭,我的应用程序会再次显示。
  4. 如果您看到我的ParseCallback done代码,您会注意到无论用户的结果如何,都应该更改片段。但是永远不会调用它,并且永远不会显示日志。

    我做了什么:

    • 我已进入我的Parse设置,并在设置中添加了我的秘密和ID (我所做的所有研究,我注意到这是很多人会做错的。检查如果你在这里寻求答案!!)
    • 我使用Facebook Sdk指南添加了Parse.com
    • 我有四倍检查我的KeyHash是否正确。
    • 我在我的应用程序ParseFacebookUtils.initialize(APPLICATION_ID);中呼叫onCreate
    • 我已经安装了FB应用程序
    • 我在模拟器和物理设备上都试过这个
    • 我完全重新启动了一个新项目,该项目仅包含更新的Parse.jar和Facebook-sdk。依然没有。

    以下是警告的完整堆栈跟踪。这对我没有好处,但也许你可以解读它:

    05-25 18:27:09.402    4515-4515/com.codealchemist D/Login Facebook﹕ BUTTON WAS PRESSED
    com.codealchemist/com.facebook.LoginActivity: +82ms
    05-25 18:27:10.002    3746-4556/com.facebook.katana W/fb4a(:<default>):BlueServiceQueue﹕ Exception during service
        com.facebook.http.protocol.ApiException: The proxied app is not already installed.
                at com.facebook.http.protocol.ApiResponseChecker.b(ApiResponseChecker.java:83)
                at com.facebook.http.protocol.ApiResponseChecker.a(ApiResponseChecker.java:162)
                at com.facebook.http.protocol.ApiResponse.g(ApiResponse.java:151)
                at com.facebook.platform.auth.server.AuthorizeAppMethod.a(AuthorizeAppMethod.java:275)
                at com.facebook.platform.auth.server.AuthorizeAppMethod.a(AuthorizeAppMethod.java:31)
                at com.facebook.http.protocol.ApiResponseHandler.a(ApiResponseHandler.java:55)
                at com.facebook.http.protocol.ApiResponseHandler.handleResponse(ApiResponseHandler.java:28)
                at com.facebook.http.common.FbHttpRequestProcessor.a(FbHttpRequestProcessor.java:314)
                at com.facebook.http.common.FbHttpRequestProcessor.a(FbHttpRequestProcessor.java:144)
                at com.facebook.http.common.FbHttpRequestProcessor.b(FbHttpRequestProcessor.java:100)
                at com.facebook.http.common.FbHttpRequestProcessor.a(FbHttpRequestProcessor.java:230)
                at com.facebook.http.protocol.SingleMethodRunnerImpl.a(SingleMethodRunnerImpl.java:402)
                at com.facebook.http.protocol.SingleMethodRunnerImpl.a(SingleMethodRunnerImpl.java:164)
                at com.facebook.http.protocol.AbstractSingleMethodRunner.a(AbstractSingleMethodRunner.java:18)
                at com.facebook.platform.common.server.SimplePlatformOperation.a(SimplePlatformOperation.java:40)
                at com.facebook.platform.common.server.PlatformOperationHandler.a(PlatformOperationHandler.java:60)
                at com.facebook.fbservice.service.BlueServiceQueue.e(BlueServiceQueue.java:329)
                at com.facebook.fbservice.service.BlueServiceQueue.d(BlueServiceQueue.java:55)
                at com.facebook.fbservice.service.BlueServiceQueue$3.run(BlueServiceQueue.java:258)
                at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:422)
                at java.util.concurrent.FutureTask.run(FutureTask.java:237)
                at com.facebook.common.executors.ListenableScheduledFutureImpl.run(ListenableScheduledFutureImpl.java:59)
                at android.os.Handler.handleCallback(Handler.java:733)
                at android.os.Handler.dispatchMessage(Handler.java:95)
                at android.os.Looper.loop(Looper.java:136)
                at android.os.HandlerThread.run(HandlerThread.java:61)
    05-25 18:27:10.002    1272-1783/system_process I/ActivityManager﹕ START u0 {cmp=com.facebook.katana/.ProxyAuth (has extras)} from pid 4515
    05-25 18:27:10.012    3746-3817/com.facebook.katana W/Settings﹕ Setting wifi_sleep_policy has moved from android.provider.Settings.System to android.provider.Settings.Global, returning read-only value.
    05-25 18:27:10.032    1272-1420/system_process I/ActivityManager﹕ START u0 {cmp=com.facebook.katana/.ProxyAuthDialog (has extras)} from pid 3746
    05-25 18:27:10.082    3746-3746/com.facebook.katana D/dalvikvm﹕ GC_FOR_ALLOC freed 2462K, 34% free 11230K/16936K, paused 20ms, total 21ms
    05-25 18:27:10.192    3746-3746/com.facebook.katana W/EGL_emulation﹕ eglSurfaceAttrib not implemented
    05-25 18:27:10.212    3746-3746/com.facebook.katana W/AwContents﹕ nativeOnDraw failed; clearing to background color.
    05-25 18:27:10.222    1272-1286/system_process I/ActivityManager﹕ Displayed com.facebook.katana/.ProxyAuthDialog: +187ms (total +206ms)
    05-25 18:27:10.292    3746-3746/com.facebook.katana W/EGL_emulation﹕ eglSurfaceAttrib not implemented
    05-25 18:27:10.592    3746-3746/com.facebook.katana E/eglCodecCommon﹕ glUtilsParamSize: unknow param 0x00000b44
    05-25 18:27:10.602    3746-3746/com.facebook.katana E/eglCodecCommon﹕ glUtilsParamSize: unknow param 0x00000bd0
    05-25 18:27:10.612    3746-3746/com.facebook.katana I/chromium﹕ [INFO:async_pixel_transfer_manager_android.cc(56)] Async pixel transfers not supported
    05-25 18:27:10.622    3746-3746/com.facebook.katana E/chromium﹕ [ERROR:gles2_cmd_decoder_autogen.h(1144)] [GroupMarkerNotSet(crbug.com/242999)!:9854F8B8]GL ERROR :GL_INVALID_OPERATION : GetIntegerv: <- error from previous GL command
    05-25 18:27:10.672    3746-3746/com.facebook.katana I/chromium﹕ [INFO:async_pixel_transfer_manager_android.cc(56)] Async pixel transfers not supported
    05-25 18:27:10.692    3746-3746/com.facebook.katana E/chromium﹕ [ERROR:gles2_cmd_decoder_autogen.h(1144)] [GroupMarkerNotSet(crbug.com/242999)!:483727B9]GL ERROR :GL_INVALID_OPERATION : GetIntegerv: <- error from previous GL command
    05-25 18:27:10.752    3746-3746/com.facebook.katana E/eglCodecCommon﹕ **** ERROR unknown type 0x0 (glSizeof,72)
    05-25 18:27:10.752    3746-3746/com.facebook.katana E/eglCodecCommon﹕ glUtilsParamSize: unknow param 0x00000b44
    05-25 18:27:10.762    3746-3746/com.facebook.katana E/eglCodecCommon﹕ glUtilsParamSize: unknow param 0x00000bd0
    05-25 18:27:10.792    3746-3746/com.facebook.katana E/eglCodecCommon﹕ **** ERROR unknown type 0x0 (glSizeof,72)
    05-25 18:27:10.872    4515-4515/com.codealchemist W/EGL_emulation﹕ eglSurfaceAttrib not implemented
    05-25 18:27:10.872    4515-4515/com.codealchemist E/HardwareRenderer﹕ An error has occurred while drawing:
        java.lang.IllegalStateException: The display list is not valid.
                at android.view.GLES20DisplayList.getNativeDisplayList(GLES20DisplayList.java:49)
                at android.view.GLES20Canvas.drawDisplayList(GLES20Canvas.java:420)
                at android.view.HardwareRenderer$GlRenderer.drawDisplayList(HardwareRenderer.java:1646)
                at android.view.HardwareRenderer$GlRenderer.draw(HardwareRenderer.java:1469)
                at android.view.ViewRootImpl.draw(ViewRootImpl.java:2381)
                at android.view.ViewRootImpl.performDraw(ViewRootImpl.java:2253)
                at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1883)
                at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1000)
                at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:5670)
                at android.view.Choreographer$CallbackRecord.run(Choreographer.java:761)
                at android.view.Choreographer.doCallbacks(Choreographer.java:574)
                at android.view.Choreographer.doFrame(Choreographer.java:544)
                at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:747)
                at android.os.Handler.handleCallback(Handler.java:733)
                at android.os.Handler.dispatchMessage(Handler.java:95)
                at android.os.Looper.loop(Looper.java:136)
                at android.app.ActivityThread.main(ActivityThread.java:5017)
                at java.lang.reflect.Method.invokeNative(Native Method)
                at java.lang.reflect.Method.invoke(Method.java:515)
                at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:779)
                at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:595)
                at dalvik.system.NativeStart.main(Native Method)
    

2 个答案:

答案 0 :(得分:1)

我也遇到了这个错误。

我删除了请求权限,然后重新开始工作。

facebook permission guide中,在部分审核中说明了

  

如果您的应用要求的不仅仅是public_profile,电子邮件和user_friends,那么在您的应用可以被应用开发者以外的人使用之前,需要通过Facebook进行审核。

     

审核您的应用的时间通常为7个工作日。如下所述,某些额外敏感的权限最多可能需要14个工作日。

所以我只减少了对这三个权限的许可,并且它正在运行。也许你的问题是这个。

答案 1 :(得分:0)

  • 卸载应用
  • 删除Facebook中的应用
  • 再试一次