Skip to content
This repository has been archived by the owner on Oct 7, 2024. It is now read-only.

Update dependencies.gradle #1358

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

oddlymagical
Copy link

@oddlymagical oddlymagical commented Jul 24, 2020

Update MinSdkVersion to 21 for Firebase compatibility.

The demo wouldn't run, was crashing instantly. Finally was able to track down the problem:

2020-07-24 09:56:38.172 7186-7186/com.mapbox.mapboxandroiddemo.debug W/FirebaseApp: Default FirebaseApp failed to initialize because no default options were found. This usually means that com.google.gms:google-services was not applied to your gradle project.
2020-07-24 09:56:38.172 7186-7186/com.mapbox.mapboxandroiddemo.debug I/FirebaseInitProvider: FirebaseApp initialization unsuccessful
2020-07-24 09:56:39.109 7186-7186/com.mapbox.mapboxandroiddemo.debug D/FirebasePerformance: Creating a new Non Verbose Session: 3d30ae187e6f466cb1a086e72b140a86
2020-07-24 09:56:39.110 7186-7186/com.mapbox.mapboxandroiddemo.debug D/FirebasePerformance: Creating a new Non Verbose Session: 2d73f3685fe24cbabed9d08b3b4bbbb0
2020-07-24 09:56:40.022 7186-7186/com.mapbox.mapboxandroiddemo.debug D/FirebasePerformance: onResume(): com.mapbox.mapboxandroiddemo.account.LandingActivity: 1885247 microseconds

This post on Stack Overflow suggested that the MinSdkVersion needed to be at least 21, not 16. I made the change and everything worked.

Update MinSdkVersion to 21 for Firebase compatibility.
@langsmith
Copy link
Contributor

Thanks @brandihaskins. Can you say more about what device you're seeing the crash on and when the app actually crashes? You're unable to do a clean install on the device? It crashes when you try to log into your Mapbox account? When you try to open a certain example?

@oddlymagical
Copy link
Author

@langsmith sure - sorry for not including more context. This is happening when trying to load the demo app onto an emulated device in Android Studio. It builds and installs without incident but when the app tries to launch it is just a brief flash on the screen. If you turn your head you can miss it.

I don't have a physical one to test with, but this was consistent across emulated nexus 6, galaxy s7, and pixel 3

Works perfect after changing the MinSdkVersion.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants