I posted about it an issue https://code.google.com/p/gmaps-api-issues/issues/detail?id=8387&thanks=8387&ts=1437921771 But still I want to know if anybody faced this and know the solution for this...
First I'm using nearBySearch http web service to get places around me via:
https://maps.googleapis.com/maps/api/place/nearbysearch/output?parameters
https://developers.google.com/places/webservice/search
Second step I use GeoDataApi.getPlaceById API for Android to get more details about the places from step 1 above. https://developers.google.com/places/android/place-details
I assume that PlaceId is 'Global reference' across all Google maps platforms. The bug is: Sometimes (and even not so rarely) PlaceID's from nearBySearch does't exist in GeoDataApi.getPlaceById, and instead I get result of this form:
{
"html_attributions" : [],
"status" : "INVALID_REQUEST"
}
PlaceID for example: ChIJJcoXzj8oAxURY8ZGJx4crNo
Edit: This is the android code:
Places.GeoDataApi.getPlaceById(mGoogleApiClient, stringIDSArray).setResultCallback(new ResultCallback<PlaceBuffer>() {
@Override
public void onResult(PlaceBuffer places) {
if (places.getStatus().isSuccess()) {
//Actually for the specified PlaceID (ain't here real "Array") we expect loop iteration
for (int i=0; i<places.getCount(); i++) {
//str is NULL for the problematic PlaceID
String str = places.get(i).getName().toString();
}
}
places.release();
}
});
Thanks,