Following the line of code throwing: grpc failed error yesterday.but today it's working fine.
List<Address> addresses=geocoder.getFromLocation(location.getLatitude(),location.getLongitude(),1);
can somebody please explain?
It looks like native Geocoder of Android API periodically experiences this issue. It was reported to Google some time ago, but looks like the issue wasn't solved definitely:
https://issuetracker.google.com/issues/64418751
Feel free to star this bug to add your vote.
As an alternative you can consider switching to Geocoding API web service that seems to be more reliable. You can use the Java client library for Google Maps API Web Services to implement web service calls from your Android app:
https://github.com/googlemaps/google-maps-services-java
This library has reverse geocoding function similar to getFromLocation. Check the javadoc for more details:
https://googlemaps.github.io/google-maps-services-java/v0.2.5/javadoc/
I hope this helps!
Related
I had a working app in Google Play. After some changes in the code and checking that is worked properly on the emulator in debug mode, I uploaded the new signed version on Google Play (as I did several times before). But the last time I did it app start to crash with "java.lang.NullPointerException" due to trying format date which is null, because my request to the server (I use retrofit2 to create a request) does not retrieve any response (that is why date is null - default value). The one of thing I changed before upload the bundle is target version from 28 to 29 (Google Play new requirement).
This is the exception I can see from Google Play console.
The app works in local machine unlike on Google Play.
I haven't got any clue what can be the reason of this problem. I'll be glad if somebody can help with any idea. Thanks in advance.
Thank you mate. You directed me into right way and I solved the issue. I use Retrofit and Gson for data serialization and several of DTOs classes but obviously ProGuard rename the fields and serialization fails. To avoid this I just add #Keep annotation to all my DTO classes and ... it works. Thank you
after removing firebase analytics, ads and crashlytics (and google-services.json), I get the following error:
java.io.IOException: Service not Available
Code:
Geocoder gcd = new Geocoder(context, Locale.getDefault());
final List<Address> addresses = gcd.getFromLocation(latlng.latitude, latlng.longitude, 1);
I don't find any explanation why this happens... Anyone here who can help me?
There is no APIKey to appy or something, right?
PS: My maps fragment is working (com.google.android.geo.API_KEY meta-data in manifest is used)
I'm running OnePlus One, Android 8.1.0 (aosp_bacon-8.1.0-20180331.agentfabulous) and gapps mini.
Seems to be a problem with my phone. I will implement this.
I'm going to close this thread.
Yes u need geocoding api key:
When i used have same problem my solution was restart phone but from reserch then i found couple solution about that.
Recreate api key
Api key get limit or bugeed
Use other for check is it blame of full service or not
Move one part to other project and check does it work if yes that meen it's problem in code somew here
Is it possible to get the "Popular times" information through the Google Places API or any other API? I need this information to be displayed in my application for a particular place.
This is one of the top feature requests in Google issue tracker (more than 500 stars):
https://issuetracker.google.com/issues/35827350
Currently, the state is Assigned, however, no any ETA provided by Google. Please star it to get further updates.
I haven't managed to test it myself but this is what populartimes offers to do in Python:
import populartimes
populartimes.get("your-api-key", ["bar"], (48.132986, 11.566126), (48.142199, 11.580047))
More info on developer's github.
It's possible to scrape it, but it violates the Google ToS.
yes its possible but as said it violates googles ToS ,
i have used npm package busy-hours but it's not working so i have modified their code and here is new npm package
https://www.npmjs.com/package/google-busy-hours
I tried decompiling an app posted on the playstore and the app has this code:
import android.location.ILocationManager
I cant replicate this on my app I get the error cannot resolve symbol. The app i'm looking at can be installed as a system app for some functions to work. Maybe this has something to do with it being a system app?
How can I get the ILocationManager class?
Late reply, but ILocationManager isn't actually a class, it's an interface. Therefore you can't instantiate it. The interface definition isn't in the android sources, but Google Sources has a version of it: ILocationManager.aidl
You can read about Android Interface Definition Language (AIDL) here.
Classes using the ILocationManager are among others Geocoder and LocationManager - have a look at them. It is used for communicating with a service on the Internet; in the case of Geocoder, to communicate with the google geocoder service.
I am trying to integrate Samsung SDK in my android project. All I need to do is to send a text message with url to the ChatOn app using the Client ChatON API. On executing this call:
int nResult = MessageAPI.sendTextMessageWithURL (getApplicationContext(), "Hello",
"http://www.chaton.com");
It returns 3 (RESULT_CODE_FAIL_EXCEPTION) with this error message: "Exception!!\nPlease, check argument"
I couldn't find any relevant documentation also on what kind of exceptions can be thrown and reasons behind them. Does anyone know more about what is the problem because of which this error code (3) is returned?
You need to install the official application of Samsung ChatON. Utility api having a method to know, Is ChatON is install or not.
The Utility API Class provides typical tools that are useful for application development by using Client APIs.
UtilityAPI.isChatONInstalled(Context context)
Utility api also provide the method by which you can get the download link of ChatON application.
UtilityAPI.openChatONDownloadPage(Context context)
for more infromation, please see this link