[
https://issues.apache.org/jira/browse/MNG-7754?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17721057#comment-17721057
]
Steven R. Loomis edited comment on MNG-7754 at 5/9/23 7:32 PM:
---------------------------------------------------------------
Thanks for improving the error message. _In the context of the build log_ (I
missed that on first review of the PR) it makes a lot more sense!
was (Author: srloomis):
Hi. I'm not sure how the error message is an improvement towards the stated
goals.
This message above says: "Some users… immediately grep their {{$HOME}} to find
out that they DO HAVE afore mentioned string present in their {{settings.xml"}}
I wouldn't know to do that. I'm just a developer, not a plugin developer. I
don't have that string anywhere in my {{pom.xml}} nor in any {{settings.xml}}
now that you say it. I do have that string in various places in
{{{}~/.m2/*{}}}.
{code:java}
[INFO] --- surefire:2.22.2:test (default-test) @ cldr-code ---
[WARNING] Parameter 'localRepository' is deprecated core expression; Avoid use
of ArtifactRepository type. If you need access to local repository, switch to
'${repositorySystemSession}' expression and get LRM from it instead. {code}
So, what can I do? I suppose I could try to upgrade surefire to 3.1.0? Sure
enough that seems to fix it.
Perhaps the error message should say: "Try upgrading <pluginname>" ?
But there's not enough context to understand the error message. I certainly
don't pass any parameter {{localRepository}} to the surefire plugin.
As I write this it's still not clear what the error is/was. What's a core
expression or an LRM? Should the message blame _surefire_ (for example) as
accessing a core expression (if indeed it did).
A confused user. Found this ticket by a web search. Thanks.
> Improvement and extension of plugin validation
> ----------------------------------------------
>
> Key: MNG-7754
> URL: https://issues.apache.org/jira/browse/MNG-7754
> Project: Maven
> Issue Type: Improvement
> Components: Core
> Affects Versions: 3.9.1
> Reporter: Tamas Cservenak
> Assignee: Tamas Cservenak
> Priority: Major
> Fix For: 3.9.2, 4.0.0-alpha-6, 4.0.0
>
>
> Some users when see following warning:
> {noformat}
> [INFO] --- remote-resources:1.7.0:process (process-resource-bundles) @ maven
> ---
> [WARNING] Parameter 'localRepository' is deprecated core expression; Avoid
> use of ArtifactRepository type. If you need access to local repository,
> switch to '${repositorySystemSession}' expression and get LRM from it
> instead. {noformat}
> on their console, immediately grep their {{$HOME}} to find out that they DO
> HAVE afore mentioned string present in their {{{}settings.xml{}}}, and then
> scratch their head how to get rid of it.
> Hence, we should improve error message – at least add some clue that message
> targets given Mojo developers (as message appears immediately under Mojo
> execution log message) and not users. Best users could do is nag Mojo
> developers, and not us, to make message disappear.
> Improvements:
> * report at end, instead multiple times same warning (for reactor builds)
> * possibility to suppress validation
> * new check: maven-compat, maven2, p-c-d, mixed maven verions,, wrong scopes
> (similar as m-p-p does on build time)
--
This message was sent by Atlassian Jira
(v8.20.10#820010)