GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Fix #11856: Improve error message for prefix-based remote repository filtering errors by gnodet · Pull Request #11888 · apache/maven

Conversation

@gnodet

@gnodet gnodet commented Apr 3, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Detect ArtifactFilteredOutException in the exception cause chain and append actionable guidance explaining that the remote repository's prefix file doesn't list the artifact's group
  • Suggest the workaround -Daether.remoteRepositoryFilter.prefixes=false and link to RRF documentation
  • Fix getReference() to return the RRF docs URL instead of the generic MojoExecutionException wiki page
  • Support https: reference URLs (previously only http: was recognized as an absolute URL)

Closes #11856

Test plan

  • Added DefaultExceptionHandlerTest.testArtifactFilteredOutException() verifying both the hint message and reference URL
  • Manual verification with a repository manager serving incomplete prefix files

🤖 Generated with Claude Code

Claude Code on behalf of Guillaume Nodet

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@gnodet @claude
Fix #11856: Improve error message for prefix-based remote repository …
d8b4c1f
…filtering errors

Co-Authored-By: Claude Opus 4.6 <[email protected]>
@gnodet gnodet added this to the 4.0.0-rc-6 milestone Apr 3, 2026
slawekjaranowski
slawekjaranowski reviewed Apr 8, 2026
View reviewed changes
Comment thread impl/maven-core/src/main/java/org/apache/maven/exception/DefaultExceptionHandler.java Outdated
Comment on lines +284 to +292
+ "This error indicates that the remote repository's prefix file does not list"
+ " this artifact's group. This commonly happens with repository managers"
+ " using virtual/group repositories that do not properly aggregate prefix files."
+ System.lineSeparator()
+ "To disable prefix-based filtering, add"
+ " -Daether.remoteRepositoryFilter.prefixes=false"
+ " to your command line or to .mvn/maven.config."
+ System.lineSeparator()
+ "See https://maven.apache.org/resolver/remote-repository-filtering.html";

@slawekjaranowski slawekjaranowski Apr 8, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It can be also from GroupId Filter, so we need to use other property aether.remoteRepositoryFilter.groupId=false

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@gnodet gnodet May 19, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code on behalf of Guillaume Nodet

Good point! Updated the error message to mention both -Daether.remoteRepositoryFilter.prefixes=false and -Daether.remoteRepositoryFilter.groupId=false so users are aware of both filter types. See 58cb40e.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@gnodet @claude
Fix #11856: Mention both prefixes and groupId filters in error message
58cb40e
The ArtifactFilteredOutException can be triggered by either the prefixes
or the groupId remote repository filter. Update the error message to
mention both properties so users know which to disable.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
@gnodet
gnodet requested a review from slawekjaranowski May 19, 2026 15:45
@gnodet
gnodet marked this pull request as ready for review May 20, 2026 17:50
slawekjaranowski
slawekjaranowski reviewed May 28, 2026
View reviewed changes
Comment thread impl/maven-core/src/main/java/org/apache/maven/exception/DefaultExceptionHandler.java Outdated
+ System.lineSeparator()
+ " -Daether.remoteRepositoryFilter.groupId=false"
+ System.lineSeparator()
+ "See https://maven.apache.org/resolver/remote-repository-filtering.html";

@slawekjaranowski slawekjaranowski May 28, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

URL is returned by getReference method

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@claude
Refactor: Convert error message string concatenation to text block
c932754
Replace multi-line string concatenation with System.lineSeparator()
calls with a cleaner text block in DefaultExceptionHandler. The error
message for ArtifactFilteredOutException now uses Java text blocks
(triple-quoted strings) instead of the + operator, improving
readability and maintainability.

Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
@gnodet
gnodet force-pushed the ci-issue-11856 branch from 5da8512 to c932754 Compare May 29, 2026 15:23
gnodet added a commit that referenced this pull request Jun 1, 2026
@gnodet @claude
Improve error message for prefix-based remote repository filtering (PR …
ded2a5a
…#11888)

Cherry-pick from ci-issue-11856 branch.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
gnodet added a commit that referenced this pull request Jun 1, 2026
@gnodet @claude
Improve error message for prefix-based remote repository filtering (PR …
a960ebc
…#11888)

Cherry-pick from ci-issue-11856 branch.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
rmannibucau
rmannibucau approved these changes Jun 2, 2026
View reviewed changes
Bukama
Bukama approved these changes Jun 4, 2026
View reviewed changes
Comment thread impl/maven-core/src/main/java/org/apache/maven/exception/DefaultExceptionHandler.java
if ((reference != null && !reference.isEmpty())
&& !reference.startsWith("http:")
&& !reference.startsWith("https:")) {
reference = "http://cwiki.apache.org/confluence/display/MAVEN/" + reference;

@Bukama Bukama Jun 4, 2026

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
reference = "http://cwiki.apache.org/confluence/display/MAVEN/" + reference;
reference = "https://cwiki.apache.org/confluence/display/MAVEN/" + reference;

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@gnodet
gnodet merged commit b404258 into master Jun 4, 2026
23 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@gnodet
gnodet deleted the ci-issue-11856 branch June 4, 2026 15:55
@github-actions

github-actions Bot commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

@gnodet Please assign appropriate label to PR according to the type of change.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@github-actions github-actions Bot assigned gnodet Jun 4, 2026
@gnodet gnodet mentioned this pull request Jun 4, 2026
[4.0.x] Fix #11856: Improve error message for prefix-based remote repository filtering errors #12234
Merged
gnodet added a commit that referenced this pull request Jun 4, 2026
@gnodet @claude
Fix #11856: Improve error message for prefix-based remote repository …
cee05ae
…filtering errors (#11888) (#12234)

* Fix #11856: Improve error message for prefix-based remote repository filtering errors



* Fix #11856: Mention both prefixes and groupId filters in error message

The ArtifactFilteredOutException can be triggered by either the prefixes
or the groupId remote repository filter. Update the error message to
mention both properties so users know which to disable.



* Refactor: Convert error message string concatenation to text block

Replace multi-line string concatenation with System.lineSeparator()
calls with a cleaner text block in DefaultExceptionHandler. The error
message for ArtifactFilteredOutException now uses Java text blocks
(triple-quoted strings) instead of the + operator, improving
readability and maintainability.



---------

Co-authored-by: Claude Opus 4.6 <[email protected]>
Co-authored-by: Claude Code <[email protected]>
@gnodet gnodet added the bug Something isn't working label Jun 23, 2026
This was referenced Jul 18, 2026
RRF: self-heal from provably broken auto-discovered prefixes files apache/maven-resolver#1976
Merged
Regression "Prefix ... NOT allowed from ..." #11856
Closed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@slawekjaranowski slawekjaranowski slawekjaranowski left review comments
@rmannibucau rmannibucau rmannibucau approved these changes
@Bukama Bukama Bukama approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@gnodet gnodet

Labels

bug Something isn't working

Projects

None yet

Milestone

4.0.0-rc-6

Development

Successfully merging this pull request may close these issues.

Regression "Prefix ... NOT allowed from ..."

Uh oh!

There was an error while loading. Please reload this page.

5 participants

@gnodet @rmannibucau @slawekjaranowski @Bukama @claude
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.