在父节点上执行mvn站点,即使其中一个子节点失败,并显示消息:
maven-site-plugin:3.10.0:site failed: The parameter 'from' cannot be null. -> [Help 1]
我找到了一个修复/可能的原因,我张贴作为答案。
我在谷歌和这里搜索了很多,但没有人报告这个问题,所以错误消息很神秘,我提出这个问题是为了给别人保存时间。
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-site-plugin:3.10.0:site (default-site) on project eleusoft_links_support: Execution default-site of goal org.apache.maven.plugins:maven-site-plugin:3.10.0:site failed: The parameter 'from' cannot be null.
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:375)
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:351)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:215)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:171)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:163)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:299)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:193)
at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:106)
at org.apache.maven.cli.MavenCli.execute (MavenCli.java:963)
at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:296)
at org.apache.maven.cli.MavenCli.main (MavenCli.java:199)
at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke (Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)
Caused by: org.apache.maven.plugin.PluginExecutionException: Execution default-site of goal org.apache.maven.plugins:maven-site-plugin:3.10.0:site failed: The parameter 'from' cannot be null.
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:148)
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:370)
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:351)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:215)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:171)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:163)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:299)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:193)
at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:106)
at org.apache.maven.cli.MavenCli.execute (MavenCli.java:963)
at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:296)
at org.apache.maven.cli.MavenCli.main (MavenCli.java:199)
at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke (Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)
Caused by: java.lang.IllegalArgumentException: The parameter 'from' cannot be null.
at org.apache.maven.doxia.tools.DefaultSiteTool.checkNotNull (DefaultSiteTool.java:1493)
at org.apache.maven.doxia.tools.DefaultSiteTool.getRelativePath (DefaultSiteTool.java:192)
at org.apache.maven.doxia.tools.DefaultSiteTool.populateParentMenu (DefaultSiteTool.java:711)
at org.apache.maven.doxia.tools.DefaultSiteTool.getDecorationModel (DefaultSiteTool.java:494)
at org.apache.maven.plugins.site.descriptor.AbstractSiteDescriptorMojo.prepareDecorationModel (AbstractSiteDescriptorMojo.java:86)
at org.apache.maven.plugins.site.render.AbstractSiteRenderingMojo.createSiteRenderingContext (AbstractSiteRenderingMojo.java:275)
at org.apache.maven.plugins.site.render.SiteMojo.renderLocale (SiteMojo.java:164)
at org.apache.maven.plugins.site.render.SiteMojo.execute (SiteMojo.java:143)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:137)
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:370)
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:351)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:215)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:171)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:163)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:299)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:193)
at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:106)
at org.apache.maven.cli.MavenCli.execute (MavenCli.java:963)
at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:296)
at org.apache.maven.cli.MavenCli.main (MavenCli.java:199)
at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke (Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)
1条答案
按热度按时间ffscu2ro1#
在我的情况下,错误是由于以下设置:
父级具有配置值为
<distributionManagement> / <site> / <url>
的URL失败的子节点尚未配置
<distributionManagement> / <site> / <url>
解决方案是将配置添加到子项或从父项中删除它。