Attempting to download a Gradle Plugin results in an error - gradle

I've been trying to work on this for hours now, but I'm not sure what the problem is specifically. If it helps, I'm doing this in Visual Studio.
Plugin [id: 'fabric-loom', version: '1.0-SNAPSHOT/'] was not found in any of the following sources:
- Gradle Core Plugins (not a core plugin, please see https://docs.gradle.org/7.5.1/userguide/standard_plugins.html for available core plugins)
- Plugin Repositories (could not resolve plugin artifact 'fabric-loom:fabric-loom.gradle.plugin:1.0-SNAPSHOT/')
Searched in the following repositories:
Fabric(https://maven.fabricmc.net/)
MavenRepo
Gradle Central Plugin Repository

Related

Issue while trying to setup the spring-boot open source project from Github

I was trying to setup the spring boot open source project in order to contribute it. I was going through the steps in here. I am on the main branch. When I try to run
./gradlew build
I am getting this error
* Where:
Settings file '<my local path>/spring-boot/settings.gradle' line: 26
* What went wrong:
Plugin [id: 'io.spring.ge.conventions', version: '0.0.12'] was not found in any of the following sources:
- Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
- Plugin Repositories (could not resolve plugin artifact 'io.spring.ge.conventions:io.spring.ge.conventions.gradle.plugin:0.0.12')
Searched in the following repositories:
MavenRepo
Gradle Central Plugin Repository
maven(https://repo.spring.io/release)
maven2(https://repo.spring.io/snapshot)
settings.gradle contains this at line 26
id "io.spring.ge.conventions" version "0.0.12"
From what I understand in the above log, gradle is trying to search for io.spring.ge.conventions but its not able to find it in those repositories. I haven't used gradle before so I am not sure what the issue is exactly and how to fix it.
These are my system details:
System: Mac(Intel)
java version "17.0.5" 2022-10-18 LTS
Editor: Intellij
I don't have gradle installed separately. I am using the gradle wrapper provided by the project.
Additionally I just commented out that line in settings.gradle and ran the build. It succeeded.
Can anyone help me out on this?

DHF mlDeploy : Plugin [id: 'net.saliman.properties', version: '1.4.6'] was not found

While I was trying to deploy marklogic DHF project 5.4.x in my local using gradle mlDeploy, I was getting UnknownPlugin exception for net.saliman.properties. I am using gradle version 6.4.
And I could see this plugin available in the repository. Any leads on solving this issue is welcome.
Where:
Build file 'C:\Users\sharu\Desktop\datahub\data-data-hub\build.gradle' line: 29
What went wrong:
Plugin [id: 'net.saliman.properties', version: '1.4.6'] was not found in any of the following sources:
Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
Plugin Repositories (could not resolve plugin artifact 'net.saliman.properties:net.saliman.properties.gradle.plugin:1.4.6')
Searched in the following repositories:
Gradle Central Plugin Repository

corporate proxy blocks plugins.gradle.org

I am trying to get a sample quarkus gradle project to run on my corporate laptop. And unfortunately plugins.gradle.org is blocked.
So I manually downloaded the two plugin dependencies and set it up in my local c:/m2/repo
The POM which include the plug in jar
<groupId>io.quarkus<groupId>
<artifactId>io.quarkus.gradle.plugin<artifactId>
<version>1.9.2.Final<version>
location : plugins.gradle.org/m2/io/quarkus/io.quarkus.gradle.plugin/1.9.2.Final
and the plug-in jar
<groupId>gradle.plugin.io.quarkus<groupId>
<artifactId>quarkus-gradle-plugin<artifactId>
<version>1.9.2.Final<version>
location: plugins.gradle.org/m2/gradle/plugin/io/quarkus/quarkus-gradle-plugin/1.9.2.Final
And I am getting the following error
- Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
- Plugin Repositories (could not resolve plugin artifact 'io.quarkus:io.quarkus.gradle.plugin:1.9.2.Final')
Searched in the following repositories:
MavenLocal(file:/C:/m2/repo/)
I noticed there are a lot of posts aroung org.gradle namespace, but none of them had proper answers.
Thanks for the help!

Why can't I download artifact through Gradle?

When gradle tries to download org.springframework.boot', version: '2.1.9.RELEASE' through Gradle Central Plugin Repository It can't do it
FAILURE: Build failed with an exception.
* Where:
Build file '/usr/src/app/build.gradle' line: 2
* What went wrong:
Plugin [id: 'org.springframework.boot', version: '2.1.9.RELEASE'] was not found in any of the following sources:
- Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
- Plugin Repositories (could not resolve plugin artifact 'org.springframework.boot:org.springframework.boot.gradle.plugin:2.1.9.RELEASE')
Searched in the following repositories:
Gradle Central Plugin Repository
But when using wget it can pull it
$ wget https://plugins.gradle.org/m2/org/springframework/boot/org.springframework.boot.gradle.plugin/2.1.9.RELEASE/org.springframework.boot.gradle.plugin-2.1.9.RELEASE.pom
--2020-07-17 13:38:07-- https://plugins.gradle.org/m2/org/springframework/boot/org.springframework.boot.gradle.plugin/2.1.9.RELEASE/org.springframework.boot.gradle.plugin-2.1.9.RELEASE.pom
Resolving plugins.gradle.org (plugins.gradle.org)... 104.18.190.9, 104.18.191.9, 2606:4700::6812:bf09, ...
Connecting to plugins.gradle.org (plugins.gradle.org)|104.18.190.9|:443... connected.
HTTP request sent, awaiting response... 200 OK
Also I tried to use our nexus proxy but it didn't help
pluginManagement {
repositories {
maven { url 'https://${NEXUS_LINK}/repository/GradlePluginPortal/' }
mavenLocal()
}
}
I have had a ton of issues with Gradle regarding this.
Two pointers:
run ./gradlew --debug through command line, check for any errors about not being able to connect - gradle does not respect proxy settings elsewhere, you have to supply them yourself in gradle.properties (like this)
try having org.gradle.jvmargs=-Djavax.net.debug=ssl in gradle.properties to see if there are SSL issues - I had "SunCertPathBuilderException: unable to find valid certification path to requested target", which was not reported when using any command line debug flags. Fixing that seems to be a pain though.

Why is grails trying to download dependency versions of working#mymachinename?

I have an existing (working) Grails 2.2.2 application. I am attempting to upgrade a dependency to a newer version. When I do this, the build fails with errors stating...
Failed to resolve dependencies
- com.google.guava:guava:working#mymachinename
- org.glassfish.hk2:hk2-api:working#mymachinename
I am really confused as to why Grails is looking for artifacts with a version of 'working#mymachinename'
I am on a private network with its own hosted Artifactory. My BuildConfig.groovy identifies Artifactory and I have successfully pulled in resources in the past.
BuildConfig.groovy
repositories {
mavenRepo name: myRepo, root: <artifactoryUrl>
}
dependencies {
runtime 'com:mydependency:1.0'
}
I can browse Artifactory and find both missing resources but with valid version numbers, 14.0.1 and 2.2.0-b10 respectively.
Has anyone seen anything like this before? Why is grails trying to download dependency versions of working#mymachinename?

Resources