I have been having gradle incompatibility issues f...
# community-support
s
I have been having gradle incompatibility issues for sometimes now while building app through cordova CLI: Test of distribution url https://services.gradle.org/distributions/gradle-8.7-bin.zip failed. Please check the values set with --gradle-distribution-url and --gradle-version. Can someone assist to provide a lead?
v
No idea what Cordova is or does, but that message is coming from the
wrapper
task. Usually you would not execute that task during normal build execution.
But as the URL is valid and works here, I guess it might be some issue on your network side, like a Firewall or Antivirus intervening, or the need to use a proxy to access the outworld but not having it configured for Gradle.
That exception should also have a cause what actually failed, so if you can make Cordova run Gradle with
--stacktrace
or
--scan
, you might get more information.
s
@Vampire Thanks for your response. Cordova is a command line tool for building hybrid mobile application using web technologies like HTML, CSS and JavaScript as againts native tool like kotlin. I disabled my Window Defender and run the command:
cordova build android
--stacktrace which logged
Could not dispatch a message to the daemon. Command failed with exit code 1: gradle -p C:\Users\USER\Desktop\AiLMS\platforms\android\tools wrapper --gradle-version 8.7
If I open and build the application using Android Studio, I will be requested to set the Gradle Path and version which will eventually work but takes too much of my time while testing. Cordova command line tool is faster but not working. I will really appreciate if you could assist in resolving this.
n
Seems more like a Cordova issue to me, so you're probably better of requesting support from that community, as they might have a deeper understanding of how Cordova uses/invokes gradle.
v
Again, if you get that error, something is most probably not right with your internet connection. It could be firewall or anti-virus, but it could also mean you need to use a Proxy and did not configure it for Gradle usage. I can hardly guess or analyze more as I'm not sitting at your computer.
s
@Niels Doucet and @Vadim Thanks for the support. I have been able to resolve it. The issue was with the System and User setting in Environment Variables for the Gradle library. I used conflicting versions. Appreciate.
👌 1
v
@Sikiru Salami I think you have mistaken me with @Vampire. I am not from Gradle support team.
v
@Vadim neither am I. I'm just a user as you, I'm not afiiliated to Gradle in any way. But as I answered, he probably meant me, yes. :-D