You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "slachiewicz (via GitHub)" <gi...@apache.org> on 2026/10/12 09:14:41 UTC
[PR] Use the runner's Maven when it is the requested version [maven-gh-actions-shared]
slachiewicz opened a new pull request, #338:
URL: https://github.com/apache/maven-gh-actions-shared/pull/338
The Set up Maven steps always run maven-wrapper-plugin and build with `./mvnw`, so every job downloads the plugin and the Maven distribution from Maven Central, and fails when Central answers 403 ([buildnumber-maven-plugin run](https://github.com/mojohaus/buildnumber-maven-plugin/actions/runs/38216266147), [native2ascii-maven-plugin run](https://github.com/mojohaus/native2ascii-maven-plugin/actions/runs/38219027743)). The step now builds with the runner's `mvn` when it reports the requested version and keeps the wrapper otherwise. Ubuntu images ship Maven 3.10.0, the default, so the fail-fast job and the Ubuntu matrix jobs no longer download Maven; the Windows and macOS images ship 3.9.16 and still use the wrapper for 3.10.0.
--
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: issues-unsubscribe@maven.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Set up Maven without the wrapper [maven-gh-actions-shared]
Posted by "slachiewicz (via GitHub)" <gi...@apache.org>.
slachiewicz commented on code in PR #338:
URL: https://github.com/apache/maven-gh-actions-shared/pull/338#discussion_r4248499568
##########
.github/workflows/maven-verify.yml:
##########
@@ -324,15 +324,64 @@ jobs:
cache: 'maven'
show-download-progress: ${{ inputs.show-download-progress }}
+ - name: Check the runner's Maven
+ id: runner-maven
+ shell: bash
+ env:
+ MAVEN_VERSION: ${{ needs.setup-maven-version.outputs.version }}
+ run: |
+ runner_version="$(mvn --batch-mode --version 2>/dev/null | sed -n 's/^Apache Maven \([^ ]*\).*/\1/p' | head -n 1)"
Review Comment:
Applied in 64b35b7: `mvn --batch-mode --version -q | head -n 1 | tr -d '\r'` gives the bare version on all three runners ([run](https://github.com/apache/maven-gh-actions-shared/actions/runs/38233201753)): `3.10.0` on Ubuntu, so those jobs build with `/usr/share/apache-maven-3.10.0` and download nothing, and `3.9.16` on Windows and macOS, which take the cached-download path. The Windows value has no trailing CR; the `^M` in the Windows log is the log's own line ending.
--
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: issues-unsubscribe@maven.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Use the runner's Maven when it is the requested version [maven-gh-actions-shared]
Posted by "slachiewicz (via GitHub)" <gi...@apache.org>.
slachiewicz commented on PR #338:
URL: https://github.com/apache/maven-gh-actions-shared/pull/338#issuecomment-6121322185
Lots of scripting unfortunately. Maybe there is another way to avoid calling Central with every build?
--
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: issues-unsubscribe@maven.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Set up Maven without the wrapper [maven-gh-actions-shared]
Posted by "slawekjaranowski (via GitHub)" <gi...@apache.org>.
slawekjaranowski commented on code in PR #338:
URL: https://github.com/apache/maven-gh-actions-shared/pull/338#discussion_r4246712807
##########
.github/workflows/maven-verify.yml:
##########
@@ -324,15 +324,64 @@ jobs:
cache: 'maven'
show-download-progress: ${{ inputs.show-download-progress }}
+ - name: Check the runner's Maven
+ id: runner-maven
+ shell: bash
+ env:
+ MAVEN_VERSION: ${{ needs.setup-maven-version.outputs.version }}
+ run: |
+ runner_version="$(mvn --batch-mode --version 2>/dev/null | sed -n 's/^Apache Maven \([^ ]*\).*/\1/p' | head -n 1)"
Review Comment:
`mvn --batch-mode --version -q` with `-q` we have only version
--
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: issues-unsubscribe@maven.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Set up Maven without the wrapper [maven-gh-actions-shared]
Posted by "slachiewicz (via GitHub)" <gi...@apache.org>.
slachiewicz merged PR #338:
URL: https://github.com/apache/maven-gh-actions-shared/pull/338
--
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: issues-unsubscribe@maven.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org