This message was deleted.
# community-support
s
This message was deleted.
p
What’s the content of your file? Without any context it’s hard to tell the error, but some plugin/your config misuses the default configuration, which should be avoided as well.
r
Have you considered a more conservative strategy to upgrading? 4.10.3 - fix all deprecation warnings 5.6.4 - fix all deprecation warnings 6.9.4 - fix all deprecation warnings 7.6.3 - fix all deprecation warnings 8.5 Quite a lot changes in gradle major versions, I'd expect to have issues leaping 4 major versions at once.
☝️ 1
👍 1
s
@Robert Elliot when trying above approach stuck at (6.9.4), * What went wrong: Execution failed for task ':generateMetadataFileForMavenJavaPublication'. > Cannot publish module metadata where component artifacts are modified.
v
Then don't modify component artifacts? :-)
r
When you were on 5.6.4, did you fix all the deprecation warnings? Does it break in the same way if you upgrade to v6.0.1? Have you worked through https://docs.gradle.org/current/userguide/upgrading_version_5.html ?
s
@Robert Elliot -> when I upgraded to 5.6.4 - Yes, I do have fixed all the deprecation & warnings -> Yes, it break in same way when I upgrade to v6.0.1
v
As I said, do not modify component artifacts.
Actually I wonder it worked before, this check is there since 4.4
Basically, you should never use
artifact
or
artifacts
on a publication, but for example add an artifact to the component you publish instead. Or if it is about sources and javadoc jars, just use the built-in functionality for them using
java { with...Jar() }
.
With Gradle 8.5 at least the error messages majorly improved and exactly say what it does not like