Maven:Non-resolvable parent POM and 'parent.relativePath' points at wrong local POM

后端 未结 6 1653
独厮守ぢ
独厮守ぢ 2021-02-02 07:35

I am using maven 3 to run the application but I am getting the following error:

[ERROR] The build could not read 1 project -> [Help 1]
org.apache.maven.projec         


        
6条回答
  •  情书的邮戳
    2021-02-02 08:19

    The normal layout for a maven multi module project is:

    parent
    ├── pom.xml
    ├── module
        ├── pom.xml
    

    Check that you use this layout.

    Additionally:

    1. the relativePath looks strange. Instead of '..'

      ..
      

      try '../' instead:

      ../
      

      You can also remove relativePath if you use the standard layout. This is what I always do, and on the command line I can build as well the parent (and all modules) or only a single module.

    2. The module path may be wrong. In the parent you define the module as:

      junitcategorizer.cutdetection
      

      You must specify the name of the folder of the child module, not an artifact identifier. If junitcategorizer.cutdetection is not the name of the folder than change it accordingly.

    Hope that helps..

    EDIT have a look at the other post, I answered there.

提交回复
热议问题