New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to use a Provider as an artifact for the maven-publish plugin #11054
Labels
a:regression
This used to work
affects-version:5.6
affects-version:6.0
in:dependency-management
DO NOT USE
in:publishing-plugins
ivy-publish maven-publish
Milestone
Comments
ljacomet
added
in:dependency-management
DO NOT USE
in:publishing-plugins
ivy-publish maven-publish
labels
Oct 18, 2019
jjohannes
added a commit
that referenced
this issue
Nov 12, 2019
This used to work in Gradle 5.5 (see #11054). The combination of #9467 and #6775 broke this. A builtBy dependency is added if the artifact is a TaskDependencyContainer, which all Providers are (#9467). This dependency was silently doing nothing in case of a plain File/String. This became an error (#6775) because a File/String is nothing that can be resolved to a task. We now only add a builtBy dependency, if the provider value or content is actually produced by a task.
jjohannes
added a commit
that referenced
this issue
Nov 12, 2019
…11329) This used to work in Gradle 5.5 (see #11054). The combination of #9467 and #6775 broke this. A builtBy dependency is added if the artifact is a TaskDependencyContainer, which all Providers are (#9467). This dependency was silently doing nothing in case of a plain File/String. This became an error (#6775) because a File/String is nothing that can be resolved to a task. We now only add a builtBy dependency, if the provider value or content is actually produced by a task.
The fix on Keeping this open in case there is a |
jjohannes
added a commit
that referenced
this issue
Nov 13, 2019
*Updated solution based on feedback to #11329* This used to work in Gradle 5.5 (see #11054). The combination of #9467 and #6775 broke this. A builtBy dependency is added if the artifact is a TaskDependencyContainer, which all Providers are (#9467). This dependency was silently doing nothing in case of a plain File/String. This became an error (#6775) because a File/String is nothing that can be resolved to a task. We now only add a builtBy dependency, if the provider value or content is actually produced by a task.
jjohannes
added a commit
that referenced
this issue
Nov 13, 2019
*Updated solution based on feedback to #11329* This used to work in Gradle 5.5 (see #11054). The combination of #9467 and #6775 broke this. A builtBy dependency is added if the artifact is a TaskDependencyContainer, which all Providers are (#9467). This dependency was silently doing nothing in case of a plain File/String. This became an error (#6775) because a File/String is nothing that can be resolved to a task. We now only add a builtBy dependency, if the provider value or content is actually produced by a task.
Picked to |
big-guy
changed the title
Using a Provider as an artifact for the maven-publish-Plugin does not work in Gradle 5.6 anymore
Cannot use a Provider as an artifact for the maven-publish plugin
Nov 15, 2019
big-guy
changed the title
Cannot use a Provider as an artifact for the maven-publish plugin
Unable to use a Provider as an artifact for the maven-publish plugin
Nov 18, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
a:regression
This used to work
affects-version:5.6
affects-version:6.0
in:dependency-management
DO NOT USE
in:publishing-plugins
ivy-publish maven-publish
Using a Provider as an artifact for the
maven-publish
-Plugin does not work in Gradle 5.6 anymore. Using a File instance still works despite the error message (see current behaviour) suggesting otherwise.Expected Behavior
The file
my-artifact.txt
should be published into the local maven repository.Current Behavior
You get the following error:
Context
This works in Gradle 5.5.1 and below, but stops working in Gradle 5.6.
Steps to Reproduce
Execute
gradlew publishToMavenLocal
in this project: gradle-issue-11054.zipFor reference here is the
build.gradle
:Your Environment
The text was updated successfully, but these errors were encountered: