jfrog / jfrog-cli

JFrog CLI is a client that provides a simple interface that automates access to the JFrog products.
https://www.jfrog.com/confluence/display/CLI/JFrog+CLI
Apache License 2.0
531 stars 231 forks source link

Error in initialization script #183

Closed ziemerz closed 6 years ago

ziemerz commented 6 years ago

When running your example project for gitlab cli with gradle, an error occurs:

* Where:
Initialization script '/root/.jfrog/dependencies/gradle.init.v2' line: 14

* What went wrong:
java.lang.UnsupportedOperationException (no error message)

* Try:
Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Exception is:
java.lang.UnsupportedOperationException
    at com.google.common.collect.ImmutableMap.put(ImmutableMap.java:326)
    at com.google.common.collect.BiMap$put.call(Unknown Source)
    at BuildInfoPluginListener.projectsLoaded(/root/.jfrog/dependencies/gradle.init.v2:14)
    at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:35)
    at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24)
    at org.gradle.internal.event.DefaultListenerManager$ListenerDetails.dispatch(DefaultListenerManager.java:370)
    at org.gradle.internal.event.DefaultListenerManager$ListenerDetails.dispatch(DefaultListenerManager.java:352)
    at org.gradle.internal.event.AbstractBroadcastDispatch.dispatch(AbstractBroadcastDispatch.java:58)

If the line gets commented out, it builds just fine, however, I can only do this on my local machine (Mac)

Command run: jfrog rt gradle "build" configuration.yaml --build-name=gitlabci-gradle-artifactory --build-number=1

jfrog cli version: 1.16.2 Gradle version: 4.8

eyalbe4 commented 6 years ago

Thanks for reporting this @ziemerz. This seems to be a compatibility issue with Gradle 4.8. This issue of the Gradle Artifactory Plugin discusses this issue. As you can see in this Jira issue, the issue has been recently fixed as part of version 4.7.4 of the Gradle Artiofactory Plugin. JFrog CLI uses this plugin as a dependency. We'll soon publish a JFrog CLI release, updating its Gradle Artifactory dependency version.

eyalbe4 commented 6 years ago

@ziemerz, Version 1.17.0 has been released and includes a fix for this issue. Please let us know if it resolves the issue for you.

eyalbe4 commented 6 years ago

@ziemerz, I'm closing this issue for now. Please let us know if you need additional hep with this.

ziemerz commented 6 years ago

@eyalbe4 I'm sorry for the late answer. For some odd reason I haven't received any notifications besides just now. Unfortunately I was a bit in a hurry, so I changed to another solution, so I can't confirm if this solved my issue.