ajaykumarsoma / flickrj-android

Automatically exported from code.google.com/p/flickrj-android
Other
0 stars 0 forks source link

findByLatLon doesn't work today, throws JSONException #2

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Seems Flickr changed the JSON format, the parsePlace should find the name in 
the "name" attribute, there is no "_content". 

Example JSON format can be generated by
http://www.flickr.com/services/api/explore/flickr.places.findByLatLon

org.json.JSONException: No value for _content
at org.json.JSONObject.get(JSONObject.java:354)
at org.json.JSONObject.getString(JSONObject.java:510)
at 
com.gmail.yuyang226.flickr.places.PlacesInterface.parsePlace(PlacesInterface.jav
a:803)
at 
com.gmail.yuyang226.flickr.places.PlacesInterface.parsePlacesList(PlacesInterfac
e.java:681)
at 
com.gmail.yuyang226.flickr.places.PlacesInterface.findByLatLon(PlacesInterface.j
ava:232)

Original issue reported on code.google.com by christof...@gmail.com on 1 Nov 2011 at 9:16

GoogleCodeExporter commented 8 years ago
This issue was closed by revision fc601974ee06.

Original comment by yuyang...@gmail.com on 23 Nov 2011 at 5:30

GoogleCodeExporter commented 8 years ago
Issue fixed, and please grab the latest version from 
https://code.google.com/p/flickrj-android/downloads/list

Original comment by yuyang...@gmail.com on 23 Nov 2011 at 5:35

GoogleCodeExporter commented 8 years ago
Thanks, works now for me too :)!

Original comment by christof...@gmail.com on 1 Dec 2011 at 8:22

GoogleCodeExporter commented 8 years ago
This issue seems to be back... with 1.0.3 as well with 2.0. And actually line 
803 of the PlacesInterface.java again checks for "_content" instead of "name". 

Did something go wrong with somebody's branch merge? Seems there is a 
regression.

Thanks and regards!

Original comment by christof...@gmail.com on 1 Sep 2012 at 11:53