jo jo
jo jo

Reputation: 1838

Android studio3.3 variantOutput.getProcessResources() is obsolete and has been replaced with 'variantOutput.getProcessResourcesProvider()

What is bellow warning:

WARNING: API 'variantOutput.getProcessResources()' is obsolete and has been replaced with 'variantOutput.getProcessResourcesProvider()'.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variantOutput.getProcessResources(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace.
Affected Modules: app

Upvotes: 8

Views: 12799

Answers (3)

sao sophea
sao sophea

Reputation: 1

I do not need to change the default of " classpath 'com.google.gms:google-services:4.2.0' ". This is the default that I copy from firebase, it really has been updated but we do not need to update it.

Upvotes: 0

kimchibooty
kimchibooty

Reputation: 339

run a gradle task with this flag -Pandroid.debug.obsoleteApi=true and it will let you know where the obsolete feature is being used.

After identifying where the issue is, you can try updating as the message suggests

ex. .gradlew app:assembleDebug -Pandroid.debug.obsoleteApi=true

Upvotes: 3

Homan Huang
Homan Huang

Reputation: 433

It's the bug in https://services.gradle.org/distributions/gradle-4.10.1-all.zip .

You need to roll back to https://services.gradle.org/distributions/gradle-4.6-all.zip in gradle-wrapper.properties

And

dependencies {
    classpath 'com.android.tools.build:gradle:3.2.1' //roll back to this version

I have deal with this bug for 4 hours. I gave up so I rolled back to last version. It's perfect now. So let's wait for the newer version. Don't upgrade, yet!

Upvotes: 15

Related Questions