Using Android Studio 3.3 Canary 11 with the gradle plugin version 3.3.0-alpha11
. It throws the following error when trying to sync gradle
WARNI
Fix is update the root build gradle files to latest. And this answer hold true now. in fureture again new change will be implementing by gradle and android SDK. At times answer will vary in due course of time.
repositories {
maven { url "https://jitpack.io" }
maven {
url 'https://maven.fabric.io/public'
}
google()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.5.0'
classpath 'com.google.gms:google-services:4.3.0'
classpath 'io.fabric.tools:gradle:1.30.0'
}
It's confirmed as bug for Crashlytics and they are working on it.
https://issuetracker.google.com/issues/116408637
Quoted from Google assignee:
je...@google.com #23 Jan 23, 2019 01:40AM
Hi all,Thank you for your patience.
It looks like the bug in all cases is coming from crashlytics and I've filed a bug with them.
I will keep you updated on the status.
For me, my debug app is working fine on my device just by running and ignoring the warning without commenting Crashlytics or Fabric. I have not try for production.
Update:
Google Issue Tracker had mark this issues as Won't Fix (Infeasible) because all the issues was from Crashlytics, and let fixes done by Crashlytics team (despite they are same Googler...).
They suggest to follow this link for Crashlytics updates:
https://github.com/firebase/firebase-android-sdk/issues/198
Note: I'm still using Android Studio 3.3 with io.fabric.tools:gradle:1.26.0 without commenting any of Craslytics and it's works fine on my debug app.
Update:
I can confirm now that it works fine on my production/release version app. How do I know it works? Because it had sent me back a crash reports -_-'
Anyway, just ignore the warning, they should fix it eventually.
Aww, just read that it had fixed with fabric 1.28.0 :)
When I opened the project, I pressed the Run migrations
button appeared on the right bottom corner from Android Studio
. A migration was performed and the problem was solve without commenting out the Crashlytics
dependency.
In my case, I needed to use io.fabric
plugin, and the solution was, to update to the latest fabric tools gradle version:
classpath 'com.android.tools.build:gradle:3.3.0'
classpath 'io.fabric.tools:gradle:1.27.0'
UPDATE
As of today you can use classpath 'io.fabric.tools:gradle:1.28.0'
to fix this issue !
If commenting out Crashlytics
's plugin io.fabric
on the app gradle file worked for you temporarily
//apply plugin: 'io.fabric'
Then upgrading your fabric gradle dependencies on the Project gradle file will permanently solve the issue:
classpath 'io.fabric.tools:gradle:1.27.0'
NB: this doesn’t remove the warnings but let you use Crashlytics with AS3.3+
EDIT
This issue has been fixed in Fabric 1.28.0. In your build.gradle
of the project level, add the following line:
classpath 'io.fabric.tools:gradle:1.28.1'
Previous Answer
It happens after I updated Android Studio to 3.3.0. apply plugin: 'io.fabric'
is the cause. I have sent a bug report to Firebase team about this issue.
You have 3 options:
Wait until the next version of Fabric plugin is released. Check the latest version here.
Downgrade to Android Studio 3.2.1.
Comment out io.fabric
plugin.
In build.gradle
of your app's module:
apply plugin: 'com.android.application'
// apply plugin: 'io.fabric' <== this plugin causes the error
However, you can still build and run your projects even though this error appears. Just ignore it.