Java 无法生成pom文件。出现未知的编译问题

Java 无法生成pom文件。出现未知的编译问题,java,maven-3,pom.xml,Java,Maven 3,Pom.xml,我正在使用maven clean install build构建项目。获取编译错误。 我还尝试更改编译器版本。但这没用 它说检测到更改-重新编译模块! 将492个源文件编译为D:..\target\classes 我被困在这里了 如果需要任何细节,请告诉我 An exception has occurred in the compiler (1.8.0_45). Please file a bug at the Java Developer Connection (http://java.sun

我正在使用maven clean install build构建项目。获取编译错误。 我还尝试更改编译器版本。但这没用

它说检测到更改-重新编译模块! 将492个源文件编译为D:..\target\classes

我被困在这里了

如果需要任何细节,请告诉我

An exception has occurred in the compiler (1.8.0_45). Please file a bug at the Java Developer Connection (http://java.sun.com/webapps/bugreport)  after checking the Bug Parade for duplicates. Include your program and the following diagnostic in your report.  Thank you.
    java.lang.AssertionError
        at com.sun.tools.javac.util.Assert.error(Assert.java:126)
        at com.sun.tools.javac.util.Assert.check(Assert.java:45)
        at com.sun.tools.javac.code.SymbolMetadata.setDeclarationAttributesWithCompletion(SymbolMetadata.java:161)
        at com.sun.tools.javac.code.Symbol.setDeclarationAttributesWithCompletion(Symbol.java:215)
        at com.sun.tools.javac.comp.MemberEnter.actualEnterAnnotations(MemberEnter.java:952)
        at com.sun.tools.javac.comp.MemberEnter.access$600(MemberEnter.java:64)
        at com.sun.tools.javac.comp.MemberEnter$5.run(MemberEnter.java:876)
        at com.sun.tools.javac.comp.Annotate.flush(Annotate.java:143)
        at com.sun.tools.javac.comp.Annotate.enterDone(Annotate.java:129)
        at com.sun.tools.javac.comp.Enter.complete(Enter.java:512)
        at com.sun.tools.javac.comp.Enter.main(Enter.java:471)
        at com.sun.tools.javac.main.JavaCompiler.enterTrees(JavaCompiler.java:982)
        at com.sun.tools.javac.main.JavaCompiler.compile(JavaCompiler.java:857)
        at com.sun.tools.javac.main.Main.compile(Main.java:523)
        at com.sun.tools.javac.api.JavacTaskImpl.doCall(JavacTaskImpl.java:129)
        at com.sun.tools.javac.api.JavacTaskImpl.call(JavacTaskImpl.java:138)
        at org.codehaus.plexus.compiler.javac.JavaxToolsCompiler.compileInProcess(JavaxToolsCompiler.java:126)
        at org.codehaus.plexus.compiler.javac.JavacCompiler.performCompile(JavacCompiler.java:174)
        at org.apache.maven.plugin.compiler.AbstractCompilerMojo.execute(AbstractCompilerMojo.java:1075)
        at org.apache.maven.plugin.compiler.CompilerMojo.execute(CompilerMojo.java:168)
        at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:137)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:210)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:156)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:148)
        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:305)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:192)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:105)
        at org.apache.maven.cli.MavenCli.execute(MavenCli.java:956)
        at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:192)
        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:497)
        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)
    [INFO] -------------------------------------------------------------
    [ERROR] COMPILATION ERROR : 
    [INFO] -------------------------------------------------------------
    [ERROR] An unknown compilation problem occurred
    [INFO] 1 error
    [INFO] -------------------------------------------------------------
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time:  19.118 s`enter code here`
    [INFO] Finished at: 2019-07-20T20:33:04 + 05:30`enter code here`
    [INFO] ------------------------------------------------------------------------
    [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.7.0:compile (default-compile) on project

这显然是一个编译器错误

谷歌搜索:

      at com.sun.tools.javac.code.SymbolMetadata.setDeclarationAttributesWithCompletion(SymbolMetadata.java:161)
。。。提供了许多具有类似堆栈跟踪的错误报告。不幸的是,他们中的大多数被关闭为“未确认”,因为记者没有费心跟进一个可复制的例子

以下是值得一看的:

这些问题似乎与包信息文件有关;e、 g.在一个目录中有两个这样的文件,或者有一个包信息文件带有不正确的
声明。提交错误报告的人员建议的解决方法包括:

  • 删除重复的package-info.java文件
  • 或者:不要在package-info.java文件中使用注释
  • 或:不要使用注释处理器
如果这没有帮助,您应该提交另一个bug报告。请确保提供足够的信息,以便Oracle工程师重现您的问题。。。或者你在浪费他们(和你)的时间


另一个解决方法可能是切换到更高版本的Java;e、 g.爪哇11。(其中一个bug报告说升级解决了他们的问题。)

错误信息非常清楚:“
…请在Java开发者连接中提交一个bug(http://java.sun.com/webapps/bugreport)在检查错误列表中是否有重复项后…
“您的jdk似乎已经过时:
1.8.0\u 45
,最新版本似乎是
1.8.0\u 221
。尝试更新它。这可能是您的JDK有问题。你能提供你的代码吗?
1.8.0_45
是(2013年10月15日)Java版本;你应该考虑升级你的JDK。我也尝试过版本1.80Y181。但还是一样