Howdy, Per, thank you for looking into this!
Could you explain what "global POM" and what "nested POM" is in this case? Thanks T On Thu, Nov 6, 2025 at 8:29 PM Per Nyfelt <[email protected]> wrote: > > Hi, > > Tamas asked me to take a look at this bug report: > https://github.com/apache/maven-resolver-ant-tasks/issues/138 > > It highlights an issue I hope to get some advice on. > > The essence of the issue is whether we should enforce a "global pom" or > not. Today we allow overriding it in the deploy task e.g: > > <target name="testDeployOverrideGlobalPom" depends="setUp"> <repo:pom > file="${project.dir}/dummy-pom.xml"/> <repo:deploy remotereporef="distrepo"> > <pom file="${project.dir}/other-pom.xml"/> </repo:deploy> </target> > > But if the user ONLY specifies the pom as a nested element inside the > deploy e.g: > > <target name="testDeployNoGlobalPom" depends="setUp"> > <repo:deploy> <repo:artifact file="${artifact.file}"> <repo:pom > file="${project.dir}/dummy-pom.xml"/> </repo:artifact> </repo:deploy> > </target> > > Then we throw an NPE on line 133 of the AbstractDistTask (because there > is no global pom). > > I have reproduced the error in a test here: > https://github.com/apache/maven-resolver-ant-tasks/pull/139 > > The question is if we should > > 1. Allow this usage (fix the NPE issue) > > 2. Not allow this and throw a BuildException stating that a global pom > must be registered before an override is specified. > > What do you think? > > Regards, > > Per --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
