huuanh1987 / facebook-java-api

Automatically exported from code.google.com/p/facebook-java-api
0 stars 0 forks source link

Desktop Applications Have been Deprecated #160

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create a JSONRestClient
2. Set isDesktopApp to true
3. Run some login code

What is the expected output? What do you see instead?

The expected output is basically nothing (no exception)

org.json.JSONException: JSONObject["secret"] not found.
    at org.json.JSONObject.get(JSONObject.java:422)
    at org.json.JSONObject.getString(JSONObject.java:593)
    at 
com.google.code.facebookapi.FacebookJsonRestClient.auth_getSession(FacebookJsonR
estClient.j
ava:276)
    at pf2.client.model.impl.FacebookClientModel.facebookLogin(FacebookClientModel.java:92)
    at 
pf2.client.controller.LocaccinoTrayController.loginConfirmed(LocaccinoTrayContro
ller.java:82)
    at 
pf2.client.controller.LocaccinoTrayController$LoginAttemptClass.run(LocaccinoTra
yController.jav
a:198)
    at java.util.TimerThread.mainLoop(Timer.java:512)
    at java.util.TimerThread.run(Timer.java:462)

What version of the product are you using? On what operating system?
2.0.4 on Windows and Mac

Please provide any additional information below.

Original issue reported on code.google.com by driel...@gmail.com on 13 Jan 2009 at 6:47

GoogleCodeExporter commented 8 years ago
Please provide a sample JUnit test.

Original comment by david.j....@googlemail.com on 13 Jan 2009 at 8:54

GoogleCodeExporter commented 8 years ago
Well, it's a difficult test case to write, because the method auth_getSession 
doesn't ACTUALLY throw 
JSONException.  Here is the best I could come up with.  You'll get the 
exception (but the JUnit test won't fail 
because it's not thrown far enough).  I use JDIC to open a browser window per 
the Facebook Desktop app login 
conventions.

Original comment by driel...@gmail.com on 15 Jan 2009 at 3:49

Attachments:

GoogleCodeExporter commented 8 years ago
Note: This work fine for me with the version 2.0.5. Is this bug fixed ?

Original comment by thorgull on 18 Feb 2009 at 10:30

GoogleCodeExporter commented 8 years ago
I have plenty of reasons to believe that this is fixed. Closing issue.

Original comment by david.j....@googlemail.com on 7 Mar 2009 at 3:34