Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ANDROID: Error W/DynamiteModule: Local module descriptor class for com.google.android.gms.googlecertificates not found

I am trying to do a MapActivity using Android Studio. It has to show the user’s location.

Well, I know I need a key in order to use the API, and believe me, I changed that key at least four times… I also have the permissions in the AndroidManifest.xml.

The thing is I can show the map without the user’s location, but if I try to show his/her location, then the app compiles well BUT when I try to execute it, it stops and I obtain this error:

11-12 09:13:28.416 21576-21653/raquel.mapapplication W/DynamiteModule: Local module descriptor class for com.google.android.gms.googlecertificates not found.
11-12 09:13:28.424 21576-21653/raquel.mapapplication I/DynamiteModule: Considering local module com.google.android.gms.googlecertificates:0 and remote module com.google.android.gms.googlecertificates:2
11-12 09:13:28.424 21576-21653/raquel.mapapplication I/DynamiteModule: Selected remote version of com.google.android.gms.googlecertificates, version >= 2
11-12 09:13:28.432 21576-21653/raquel.mapapplication W/System: ClassLoader referenced unknown path: /data/user/0/com.google.android.gms/app_chimera/m/0000000b/n/armeabi
11-12 09:13:28.436 21576-21653/raquel.mapapplication D/GoogleCertificates: com.google.android.gms.googlecertificates module is loaded
11-12 09:13:28.504 21576-21653/raquel.mapapplication D/GoogleCertificatesImpl: Fetched 190 Google release certificates
11-12 09:13:28.505 21576-21653/raquel.mapapplication D/GoogleCertificatesImpl: Fetched 363 Google certificates
11-12 09:13:31.235 21576-21576/raquel.mapapplication I/Process: Sending signal. PID: 21576 SIG: 9

It mentions something about Google Certificates, and that is why I thought maybe it has something to do with the key… But I am not sure and I do not have idea what I am doing wrong.

Thank you for your help.

////////

Ok, I will try to post some code... I have been changing the code all the time, but this is the last I tried (I also tried setMyLocationEnable(true), because getMyLocation() is deprecated, but I obtain the same error):

public class MapsActivity extends FragmentActivity implements OnMapReadyCallback {

    private GoogleMap mMap;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_maps);
        // Obtain the SupportMapFragment and get notified when the map is ready to be used.
        SupportMapFragment mapFragment = (SupportMapFragment) getSupportFragmentManager()
                .findFragmentById(R.id.map);
        mapFragment.getMapAsync(this);
    }

    @Override
    public void onMapReady(GoogleMap googleMap) {
        mMap = googleMap;

        Location location=mMap.getMyLocation();

        double lat=location.getLatitude();
        double lon=location.getLongitude();

        // Add a marker in Sydney and move the camera
        LatLng sydney = new LatLng(lat, lon);
        mMap.addMarker(new MarkerOptions().position(sydney).title("Marker in Sydney"));
        mMap.moveCamera(CameraUpdateFactory.newLatLng(sydney));
    }
}

Thanks the person who answered me and the person who edited my comment... I still do not well how to format text...

like image 406
Raquel Romero Sanabria Avatar asked Nov 12 '16 09:11

Raquel Romero Sanabria


1 Answers

Open the sdk manager, download/update google play services. And create a new emulator.

like image 107
Pablo Cegarra Avatar answered Nov 09 '22 12:11

Pablo Cegarra