Ayush0612005 commented on PR #284: URL: https://github.com/apache/maven-artifact-plugin/pull/284#issuecomment-6628600038
I found this PR while preparing the follow-up to my tests-first reproduction on #281, and would like to contribute supporting coverage here. I have a six-invocation Invoker fixture available in this fork commit: https://github.com/Ayush0612005/maven-artifact-plugin/commit/7ebca83b7515e18d249bd9c439bf1ea7f24233c5 The fixture installs reproducible artifacts, compares through the original `central` ID and the explicit mirror ID, checks URL and `id::url` references, and requires an unknown ID to fail with the specific diagnostic. It uses a distinct mirror-settings filename because Invoker interpolates settings into a shared directory by basename. On my candidate implementation, 11 unit tests and all 18 integration projects pass; I also reran the fixture after making its file-count assertion tolerate Maven 4's additional build POM. I haven't run your full PR/harness dependency changes. One compatibility edge to clarify: the current single loop can match an earlier mirror's original ID before a later effective repository whose own ID is the requested ID. For a supplied repository list `[mirror-central (mirrors central), central]`, requesting `central` previously returned the effective `central` entry; at `236a49f20516ddd10e5c587f01d49f0e8c412cf9`, it returns `mirror-central` instead. An exact-ID pass before the original-ID fallback retains the old precedence. I checked that selector from your PR in isolation with seven selection cases: six pass, and the exact-ID precedence case fails with the expected repository-instance mismatch (no test errors). This is a constructed repository-list edge case, not a reproduced production configuration; if Resolver guarantees that layout cannot occur, it may not require a change. Is preserving explicit effective-ID precedence the desired contract here? Happy to provide just the Invoker fixture and/or adapt that preservation test to your new harness, keeping this PR as the implementation path. AI assistance: Codex helped prepare and run these checks and draft this comment. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
