The Android project failed to run

1, compile Gradle exception information Error: Unable to find method ‘org. Gradle. API. The tasks. TaskInputs. The file (Ljava/lang/Object) Lorg/gradle/api/tasks/TaskInputFilePropertyBuilder; ‘.

Minimum Supported Gradle version is 6.1.1. Current version is 5.6.4

why

Gradle version in the project does not match Gradletool

Project gradletool is revised as follows: the classpath ‘com. Android. View the build: gradle: 3.6.0’

Change the distributionUrl in the gradle-wrapper.properties file to:

https://services.gradle.org/distributions/gradle-5.6.4-all.zip
Copy the code

These two versions are compatible versions

The following is a list of Android gradle versions and tool plugin versions