Tag Archives: Failed to notify build listene

Some processing experiences of failed to notify build listener

When writing a demo, there is a problem as follows:

Failed to notify build listener.

When searching on the Internet, it’s all about the current gradle problem. What is the specific problem?I found one of the Blogs:

https://blog.csdn.net/Evan_ L/article/details/87368075

What I’m saying is that the current gradle version supported by Android studio may not be consistent with the version you expect to use in your project and development tools.

So how do we check?We can carry out the following steps:

1. Check the gradle version you expect to use, and enter gradlew – V in terminal in Android studio. (if you have configured gradle environment, enter gradle – V in CMD) as shown in the figure below:

You can see that my version number here is 5.1.1.

2. Check the gradle version supported by your current Android studio. The location is the gradle folder in your Android studio directory. As shown in the figure:

You can see that I support 4.6 here. So to sum up, my initial judgment is that my expected gradle version is too high. So I need to make my gradle version a little lower to meet the needs of my android studio. How to change it

Here, just change your gradle version to the latest version supported by Android studio. After the change, remember to change the version number of the gradle plug-in, otherwise there will be problems. As shown in the figure:

Remember that the version number of the plug-in here must be changed to correspond to the version number of gradle. The specific corresponding relationship can be viewed on Android’s official website. Here is a link:

https://developer.android.google.cn/studio/releases/gradle-plugin.html#updating-plugin

Then, after the version number is mapped, you may need to change some dependent version numbers. Just follow the prompts. I can only say that’s how my problem was solved. I hope I can help you. Of course, what I said may not be right. I hope Daniel can see it and don’t laugh at us.

If you find that there may be something wrong with my blog, you can check this:

https://blog.csdn.net/qq_ 21397217/article/details/65630730