Facebook test app stopped working, production app works fine (using JS SDK) - facebook

I have a FB app that my website uses for the FB Login button. This app has been public for some time, and works great in production. I created a test app for my dev environments, and this too has been working fine until last week, when I suddenly started seeing this message in the browser console:
Application Error: There was a problem getting data for the application you requested. The application may not be valid, or there may be a temporary glitch. Please try again later.
This happens after I call FB.init() -- a call to FB.getLoginStatus() triggers this error, and the callback passed to FB.getLoginStatus() is never invoked. Again, this only happens in my development environments, not production, although the XFBML button still triggers a popup.
I copied the basic SDK code from FB's documentation, placed it in its own page, and still have this problem, so it is not something on my website's pages that is interfering.
I've tried searching SO/Google for answers, but the only real information I get is from back in 2011/12/13 and involved FB apps being in development mode; mine is not, it is public. I've tried creating a new test app and changing the FB ID that my website uses, but I get the same result.
The only change to (all) of my environments made recently is that they're all using SSL by default. Could this possibly be the cause? And if so, why would it work in my production environment but not in my development environments? Any insight is much appreciated.
EDIT: Using SDK v2.4, if that matters.
EDIT 2: This only seems to happen if the user is not logged into FB at all. If they have logged in externally, the SDK seems to recognize that and the call to FB.getLoginStatus() works fine.

Looks like it's a Facebook bug: https://developers.facebook.com/bugs/252572561775079/

Check that your Facebook app is "live and available to all users" and not in development mode, otherwise you'll get this error.
Go to https://developers.facebook.com/apps/ > open your app > App Review > "Make [App Name] public?" > YES

Related

Facebook Testers Can't run my Facebook Dev Canvas App

I have taken the following steps:
On the Facebook dashboard, I created a Facebook App.
Also on the dashboard, I created a test app as a child of the Facebook app (the Dev version, for testing).
I uploaded a build of my app, and confirmed I could run it from the
admin account.
I gave two of my real-world Facebook friends the Tester role in the
dashboard.
When the real-world friends try running the app, they get 404 errors
"the requested URL was not found on this server" when it tries loading
"https://apps-APP_ID.apps.fbsbx.com/hosted-canvas/e30=/.
I am using Facebook's Simple Application Hosting. The url for the app is "https://apps.facebook.com/APP_ID". When the admin hits this it works fine, when the Tester hits it they get the error. Some have suggested that there is a sandbox setting that needs to be turned off, but I see no such thing in any of the settings on the Dashboard. Any insights you could offer would be greatly appreciated.
Not sure if it helps anyone figure it out, but the app consists only of a data file, a Javascript file (xxx.js), and an index.html.
Holy moly - alright I'm hoping this helps someone else out. Apparently, when you create an app, and then create a test app so that you can establish a dev environment for testing - which is standard procedure - you have to add any testers to the parent (production) app under "Roles". I was only adding it under "Roles" for the test app, which apparently is not enough. If anyone from Facebook is reading this, please update your docs, or update the dashboard to issue a warning to people who only add testers under the test app.
We also have to push the app to production (though yet to approved),
If the status is set to "testing", only admin user can find it in my case.

What's the correct way to authorize PhoneGap application to the Facebook?

I spent a while already to fix annoying issue with Facebook in PhoneGap app. And still a lot of things goes wrong with that. The thing is that I use Appery.io and Facebook plugin.
This is how my Facebook console looks now:
I suggest that localhost might be a reason of the issue. However, I got it into Facebook_Helper.js:
Everytime I try to sign in with FB account, I get the same error at the child window:
So what I've got is that app is authorized at this moment indeed, because there's a menu button at the navbar that allows me to navigate through FB profile:
The first issue lies in that the child window never gets closed automatically once user submitted Sign In form. And the second one is that I can't get the access token to the app directly. I know I'm doing something wrong, but I spend more than a week on that and nothing was clarified.
Honestly, I've no idea why it's not working. I saw a lot of apps written in PhoneGap that use the same authorization too, and they work as it should. Will be appreciate if you take a look into that and, maybe, advice something.
First, I don't see iOS or Android in your developer.facebook screenshot.
Second, you should implement native facebook integration if you are developing an app, if I understand correctly from your code, you are trying to handle only web browser version of authentication. Native integration is both the suggested way by facebook and platforms and better experience for end users. If users have facebook app installed, authenticating over fb app is more secure after all..
You can use a cordova plugin for facebook integration, here is one of the plugins (I am one of the authors): cordova-facebook plugin

FB.init() callback stopped been called

I know that there are similar question, but I think that my situation might be different.
I have two facebook applications. One is for develop - it works in sandbox mode and works with localhost. The other one is for production, with the sandbox mode off and an active ssl.
I haven't used develop app for some time, and now I've found that FB.init() is not called anymore. However, in Google Chrome browser everything works fine, and production server works in all browsers. What can be the reason of this problem? Did Facebook got some king of update or something like that? Maybe it stopped to work because develop app needs SSL too?
Took me some time, but I figured it out. Now to use your develop non ssl applications on facebook, first you have to go into Security tab in facebook account settings and set Secure Browsing to disabled.
What I can't understand, why I haven't got any notification from facebook about this issue? If there was some kind of notification, then it was too hidden.

iOS and Facebook Graph API: Inconsistent authorize issues

I'm using the official FBConnect library for iOS and trying to get it working in my iPad app. Here's what's strange: when my friend logs in using the call to authorize:permissions:delegate, everything works fine: the dialog asks for his authorization to connect to Facebook, the fbDidLogin delegate method gets called, all is well.
However, when I try to login, the dialog never changes. The keyboard is dismissed, the password field is cleared and it just sits there. The issue is the same in both the simulator and on the device.
Here are the things I've checked and triple checked:
My login name and password are correct. If I do put in the wrong password, an "invalid username/password" message appears, and that isn't happening.
The application is not in sandbox mode.
The Application ID is correct (my friend can login without problems).
Some additional information:
Original application was created by my friend.
I created a second FB app and put in the new Application ID
My friend can login with the new Application ID
I can log in to neither.
This appears to suggest that there is something different about my friend's account, rather than the app itself.
We've been banging our heads together on this for a couple of days now. What could be causing this behaviour? Why isn't an error being generated?
Edit: It seems there are a lot of people affected by this, so in the interest of trying to find an answer, I've added a bounty.
There appears to be a server-side problem with Facebook logins as noted here:
http://github.com/facebook/facebook-ios-sdk/issues#issue/95
People have said that if they change their password on Facebook they are subsequently able to log in using the Facebook-iOS-SDK downloaded from github. Obviously that is a poor long-term solution and would be unacceptable in an app released through the App Store. On the bright side, there seem to be reports of similar login problems logging in from apps on other platforms as well.
Update: Facebook has a bug filed on this subject that can be viewed here:
http://bugs.developers.facebook.net/show_bug.cgi?id=13199

Blank popup with FB connect

I've implemented the facebook connect using Javascript SDK. The authentication works fine when the user I'm trying to authenticate is not logged into facebook. But when he's already logged into facebook the login popup never closes. The url of the popup starts with "http://static.ak.fbcdn.net/connect/xd_proxy.php#cb=....."
This happens both on Firefox 3.5 and on Chrome.
Any suggestions? Do I need to set any extra parameters while connecting to Facebook?
I've encountered the same error today, with my year old implementation. I've added the channelUrl tag to FB.Init(), without any luck; so I started the login procedure from scratch with the js sdk, oauth2 enabled: with some minor changes, everything started to work misteriously again. I've run my pages through the Facebook debug tool as well, it suggested some changes as well.
To sum up: basically, if Facebook Connect stops working, upgrade your code according to the latest documentation avaliable.
No special parameters are needed. This is probably a browser problem. Maybe you have a setting/plugin somewhere that does not allow Javascript to close a window for you.
The easiest way to test this is to post a link to your implementation so that other people (with other browser setups) can give it a try.