Matei David
11/16/2025, 12:33 AMafterEvaluate , I tried to listen to publications as they are defined with publishing.publications.configureEach {} however, I found out that a publication's artifacts need not be known/defined when the publication is added. Next, I tried publication.artifacts.configureEach {} but this eventually results in strange errors about metadata. I looked a bit around, and I believe publication.artifacts is currently not "lazy enough", so that when I do publication.artifacts, it eagerly populates something too early, resulting in problems later on. I'm not sure if afterEvaluate would really help here. Any other suggestions how to detect duplicate publications reliably?Vampire
11/16/2025, 10:15 AMcheck?Matei David
11/18/2025, 5:19 PMconflictingPublications provider at the script level, returning a List<String> , then redefining it inside tasks withType<AbstractMavenPublishTo> (so as to avoid capturing the script reference), then using the list inside an onlyIf block in each task. But this fails with "the value of this property has been discarded during serialization". Is there a way to fix this? Ideally the list of publications to disable should be computed only once.Matei David
11/18/2025, 6:24 PM