feat(dev/release): verify binary JARs on Windows - #4624
Conversation
|
That said, even with LLMs, I'm still tempted to declare that verification will require Python and just unify the verification scripts across platforms rather than maintain both PowerShell and Bash versions. |
- Add a skeleton for binary verification - Add options (like the Unix script) to control what to verify - Add Java JAR verification by testing a minimal Maven project On a Windows VM I've used the 24 RC1 artifacts (which are still present) to validate that the test fails as expected. Part of apache#4583. Assisted-by: GPT 5.6 Sol <codex@openai.com>
|
I'll fix this separately. #4639 |
amoeba
left a comment
There was a problem hiding this comment.
I'm supportive of having a single bash script for all paltforms. The deps we need on Windows are pretty easy to acquire.
| # Use conda, mamba appears to ignore --force | ||
| conda remove -y --force gtest | ||
| # Activating doesn't appear to set GOROOT | ||
| $env:GOROOT = $(Join-Path $ArrowTempDir conda-env go) |
There was a problem hiding this comment.
We should make any use of Join-Path compatible with Powershell 5 which is default. Only newer Join-Path supports more than two args to Join-Path.
| $env:GOROOT = $(Join-Path $ArrowTempDir conda-env go) | |
| $env:GOROOT = $(Join-Path $ArrowTempDir $(Join-Path conda-env go)) |
| if ($TestJars) { | ||
| Show-Header "Verify Java JARs" | ||
| if ($env:JAVA_HOME -eq $null) { | ||
| $env:JAVA_HOME = & java -XshowSettings:properties -version 2>&1 | Select-String "java.home" | ForEach-Object { $_.ToString().Split("=")[1].Trim() } |
There was a problem hiding this comment.
When I test this locally, I error at this step:
============================================================
Verify Java JARs
============================================================
java.exe : Property settings:
At C:\Users\Bryce\src\apache\arrow-adbc\dev\release\verify-release-candidate.ps1:246 char:30
+ ... nv:JAVA_HOME = & java -XshowSettings:properties -version 2>&1 | Selec ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (Property settings::String) [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError
Claude thinks this is because of setting,
$ErrorActionPreference = "Stop"earlier in the script. This was its suggestion which seems reasonable:
| $env:JAVA_HOME = & java -XshowSettings:properties -version 2>&1 | Select-String "java.home" | ForEach-Object { $_.ToString().Split("=")[1].Trim() } | |
| $javaPath = (Get-Command java).Source | |
| $env:JAVA_HOME = Split-Path (Split-Path $javaPath -Parent) -Parent |
Tested locally and it works.
On a Windows VM I've used the 24 RC1 artifacts (which are still
present) to validate that the test fails as expected.
This is intentionally minimal. It can be extended for other
platforms and binaries next.
Part of #682.
Part of #4583.
Assisted-by: GPT 5.6 Sol codex@openai.com