You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Guillaume Nodet (Jira)" <ji...@apache.org> on 2023/08/29 11:34:00 UTC

[jira] [Closed] (MNG-7851) Error message when modelVersion is 4.0 is confusing

     [ https://issues.apache.org/jira/browse/MNG-7851?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Guillaume Nodet closed MNG-7851.
--------------------------------
    Resolution: Fixed

> Error message when modelVersion is 4.0 is confusing
> ---------------------------------------------------
>
>                 Key: MNG-7851
>                 URL: https://issues.apache.org/jira/browse/MNG-7851
>             Project: Maven
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 3.9.3
>            Reporter: Craig
>            Assignee: Guillaume Nodet
>            Priority: Minor
>             Fix For: 4.0.0-alpha-8, 3.9.5
>
>
> When a pom with modelVersion 4.0 is referenced, such as this one:
> {code:xml}
> <project>
>   <modelVersion>4.0</modelVersion>
>   <groupId>foo</groupId>
>   <artifactId>bar</artifactId>
>   <version>0.1</version>
> </project>
> {code}
> The error message is:
> {{'modelVersion' of '4.0' is newer than the versions supported by this version of Maven: [4.0.0]. Building this project requires a newer version of Maven.}}
>  
> That's misleading.
> A better error message would be:
> {{'modelVersion' must be one of [4.0.0] but is '4.0'.}}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)