Skip to content

fix(modem-dev/hunk): support windows/amd64 for >= v0.12.0-beta.2 - #58616

Merged
suzuki-shunsuke merged 4 commits into
aquaproj:mainfrom
elucid:fix/modem-dev-hunk-windows
Aug 12, 2026
Merged

suzuki-shunsuke merged 4 commits into
aquaproj:mainfrom
elucid:fix/modem-dev-hunk-windows

Conversation

@elucid

@elucid elucid commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor

Check List

The bug

On Windows, aqua i for modem-dev/hunk exits 0 and installs nothing. supported_envs
lists only linux and darwin, so aqua skips the package as unsupported — a skip rather
than an error, so there is no diagnostic and no hunk command afterwards. hunk has
published hunkdiff-windows-x64.tar.gz since v0.12.0-beta.2; this entry predates that.

Fix

  • Split the trailing version_overrides entry: semver("<= 0.12.0-beta.1") keeps the
    linux/darwin-only supported_envs, and the "true" entry adds windows/amd64. The
    split is required — appending windows/amd64 to the existing "true" entry turns
    today's silent skip into a hard the asset isn't found: hunkdiff-windows-x64.tar.gz
    failure for every release from v0.6.2 to v0.12.0-beta.1.
  • windows/amd64 rather than bare windows, because hunk publishes no Windows arm64
    asset. windows_arm_emulation is not set — untested, so out of scope here.
  • No .exe handling is needed: aqua's
    completeWindowsExtToFileSrc
    appends the extension, so the existing src: "{{.AssetWithoutExt}}/hunk" resolves to
    hunkdiff-windows-x64\hunk.exe.
  • pkg.yaml: added v0.12.0-beta.2, v0.12.0-beta.1 and v0.11.1 in long syntax, so CI
    covers the new branch and both sides of the boundary. No existing test version was
    removed and the updater-owned modem-dev/hunk@v0.18.0 line is untouched.

Verification

argd t modem-dev/hunk — exit 0. On windows/amd64 it installs v0.12.0-beta.2 and
v0.18.0 and skips v0.12.0-beta.1 / v0.11.1 / v0.6.1; windows/arm64 skips cleanly. Those
are the two windows-latest legs in wc-test.yaml. darwin and linux (amd64 + arm64)
resolve exactly as before this change.

argd t only simulates Windows via AQUA_GOOS, so I also reproduced it on real hardware:

Real Windows reproduction — environment, aqua.yaml, before/after

aqua 2.62.3, Windows 11 Pro 25H2 build 26200, amd64 (env=windows/amd64), PowerShell
5.1. The registry is fetched over aqua's real github_content path pinned to this PR's
head commit, not a local file registry.

---
registries:
  - name: hunk-pr
    type: github_content
    repo_owner: elucid
    repo_name: aqua-registry
    ref: 37434b7b5f86667eaca20ea4d7da8012fd25c7a0
    path: pkgs/modem-dev/hunk/registry.yaml
packages:
  - name: modem-dev/hunk@<VERSION>
    registry: hunk-pr
$env:AQUA_DISABLE_POLICY = "true"   # only because this is not the standard registry
$env:AQUA_ROOT_DIR = "C:\aquapr\<case>\root"
$env:AQUA_CONFIG   = "C:\aquapr\<case>\aqua.yaml"
aqua i; aqua which hunk; hunk --version

Before — current main (ref: 608d3508d9). Expected hunk installed; actual exit 0,
nothing installed:

> aqua i
# (only aqua-proxy) EXIT=0
> aqua which hunk
ERR aqua failed env=windows/amd64 exe_name=hunk error="command is not found"
# EXIT=1

After — this PR:

> aqua i
INF download and unarchive the package env=windows/amd64 package_name=modem-dev/hunk package_version=v0.18.0 registry=hunk-pr
# EXIT=0
> aqua which hunk
C:\aquapr\PR-v0.18.0\root\pkgs\github_release\github.com\modem-dev\hunk\v0.18.0\hunkdiff-windows-x64.tar.gz\hunkdiff-windows-x64\hunk.exe
> hunk --version
0.18.0

aqua which is the interesting line: the entry never mentions .exe, and aqua still
resolved hunk.exe.

Full matrix on windows/amd64 — both sides of the boundary behave as intended:

pinned version aqua i installed hunk --version
v0.18.0 0 hunk.exe 0.18.0
v0.12.0 0 hunk.exe 0.12.0
v0.12.0-beta.2 0 hunk.exe 0.12.0-beta.2
v0.12.0-beta.1 0 (skipped, no error) —
v0.11.1 0 (skipped, no error) —
v0.6.1 0 (skipped, no error) —

Without the version split, the same run against v0.11.1 fails hard:

ERR install the package env=windows/amd64 package_name=modem-dev/hunk package_version=v0.11.1 error="the asset isn't found: hunkdiff-windows-x64.tar.gz"
# EXIT=1

On argd s

I ran argd s modem-dev/hunk rather than hand-editing blind. The generated config omits
files[].src from all three version_overrides branches. hunk's binary is nested inside
a directory in the archive (hunkdiff-linux-x64/hunk), so without files[].src nothing
installs on any platform, and argd t fails on linux/amd64:

ERR check file_src is correct ... package_version=v0.18.1 file_name=hunk
    exe_path=.../hunkdiff-linux-x64.tar.gz/hunk error="check file_src is correct: exe_path isn't found"
ERR argd failed error="Linux/Darwin tests failed: test failed for linux/amd64: exit status 1"

This matches the note in docs/guide.md that files cannot be auto-generated. I
therefore followed docs/guide.md → "Modifying Existing Packages": starting from the
generated output and restoring files[].src yields a config identical to this PR, which
passes argd t cleanly. Two things from the generated output I did not adopt:
windows_arm_emulation: true (hunk ships no Windows arm64 asset, and I have not tested
emulation) and the v0.18.0 → v0.18.1 bump in pkg.yaml (that pin is owned by
aqua-registry-updater).

AI disclosure per docs/ai.md:
prepared with Claude Code, credited as a commit co-author. I reviewed the configuration
and reproduced every result above myself.

elucid and others added 2 commits August 11, 2026 16:01
On Windows, `aqua i` installed nothing and exited 0, because `supported_envs`
listed only `linux` and `darwin`, so aqua skipped the package as unsupported
on that environment.

hunk publishes `hunkdiff-windows-x64.tar.gz` from v0.12.0-beta.2 onwards, so
the trailing `version_overrides` entry is split rather than edited in place:
versions below that keep the linux/darwin-only `supported_envs`, and the
latest entry adds `windows/amd64`. Without the split, `aqua i` fails on the
older versions with `the asset isn't found: hunkdiff-windows-x64.tar.gz`.

I checked every hunk release: v0.12.0-beta.2 is the exact boundary. Every
release semver-below it lacks the Windows asset and every release from it
onwards has it, so no version is misclassified by either branch.

`windows/amd64` rather than bare `windows`, because hunk publishes no Windows
arm64 asset.

No `.exe` handling is needed: aqua appends the Windows extension to
`files[].src` itself, so the existing `{{.AssetWithoutExt}}/hunk` resolves to
`hunkdiff-windows-x64/hunk.exe`.

pkg.yaml pins v0.11.1 so CI exercises the new lower branch as well as the
latest one.

Co-authored-by: Claude <noreply@anthropic.com>
Generated by `argd gr`.

Co-authored-by: Claude <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

Sponsor Our Project

We dedicate a significant amount of time every day to maintaining aqua and aqua-registry.
Today, aqua-registry is used not only by aqua itself, but also by projects such as mise and Docker Agent.
If you find these projects useful, please consider supporting us through GitHub Sponsors.

https://github.com/sponsors/aquaproj

elucid and others added 2 commits August 11, 2026 16:33
Two review follow-ups, no behaviour change:

Spell the new boundary as `semver("<= 0.12.0-beta.1")` instead of
`semver("< 0.12.0-beta.2")`. The two are equivalent -- the only 0.12.0
prereleases are beta.0, beta.1 and beta.2, so nothing sorts between them --
but `<=` is what `argd s` generates for this package, matches the style note
in docs/guide.md, and matches the `<= 0.6.1` boundary already in this file.

Pin v0.12.0-beta.1 and v0.12.0-beta.2 in pkg.yaml so CI proves the boundary
from both sides: beta.1 is the last release without a Windows asset and must
be skipped on Windows, beta.2 is the first with one and must install there.
Previously the pinned versions all sat well away from the boundary this PR
is about.

Co-authored-by: Claude <noreply@anthropic.com>
Generated by `argd gr`.

Co-authored-by: Claude <noreply@anthropic.com>
@elucid
elucid marked this pull request as ready for review August 11, 2026 20:45
@github-actions

Copy link
Copy Markdown

@suzuki-shunsuke Ready for review

@suzuki-shunsuke suzuki-shunsuke added this to the v4.550.1 milestone Aug 12, 2026
@suzuki-shunsuke

Copy link
Copy Markdown
Member

Thank you!

@suzuki-shunsuke
suzuki-shunsuke merged commit 93b4b3e into aquaproj:main Aug 12, 2026
34 of 36 checks passed
@github-project-automation github-project-automation Bot moved this to Done in main Aug 12, 2026
tmeijn pushed a commit to tmeijn/dotfiles that referenced this pull request Aug 18, 2026
This MR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [aquaproj/aqua-registry](https://github.com/aquaproj/aqua-registry) | minor | `v4.550.0` → `v4.553.0` |

MR created with the help of [el-capitano/tools/renovate-bot](https://gitlab.com/el-capitano/tools/renovate-bot).

**Proposed changes to behavior should be submitted there as MRs.**

---

### Release Notes

<details>
<summary>aquaproj/aqua-registry (aquaproj/aqua-registry)</summary>

### [`v4.553.0`](https://github.com/aquaproj/aqua-registry/releases/tag/v4.553.0)

[Compare Source](aquaproj/aqua-registry@v4.552.0...v4.553.0)

[Issues](https://github.com/aquaproj/aqua-registry/issues?q=is%3Aissue+milestone%3Av4.553.0) | [Merge Requests](https://github.com/aquaproj/aqua-registry/pulls?q=is%3Apr+milestone%3Av4.553.0) | <aquaproj/aqua-registry@v4.552.0...v4.553.0>

#### 🎉 New Packages

[#&#8203;58882](aquaproj/aqua-registry#58882) [uutils/sed](https://github.com/uutils/sed) - Rewrite of sed in Rust [@&#8203;yashikota](https://github.com/yashikota)
[#&#8203;58935](aquaproj/aqua-registry#58935) [cloudsmith-io/cloudsmith-cli](https://github.com/cloudsmith-io/cloudsmith-cli) - Cloudsmith Command Line Interface (CLI) [@&#8203;cloudsmith-iduffy](https://github.com/cloudsmith-iduffy)

### [`v4.552.0`](https://github.com/aquaproj/aqua-registry/releases/tag/v4.552.0)

[Compare Source](aquaproj/aqua-registry@v4.551.0...v4.552.0)

[Issues](https://github.com/aquaproj/aqua-registry/issues?q=is%3Aissue+milestone%3Av4.552.0) | [Merge Requests](https://github.com/aquaproj/aqua-registry/pulls?q=is%3Apr+milestone%3Av4.552.0) | <aquaproj/aqua-registry@v4.551.0...v4.552.0>

#### 🎉 New Packages

[#&#8203;58648](aquaproj/aqua-registry#58648) [OpenRouterLabs/ori-releases](https://github.com/OpenRouterLabs/ori-releases) - Ori CLI release repo [@&#8203;L0RD-ZER0](https://github.com/L0RD-ZER0)

#### Security

[#&#8203;58853](aquaproj/aqua-registry#58853) mekedron/wolt-cli: GitHub artifact attestations config [@&#8203;sanchpet](https://github.com/sanchpet)
[#&#8203;58722](aquaproj/aqua-registry#58722) masutaka/github-nippou: update to 4.3.2, add GH artifact attestations config [@&#8203;scop](https://github.com/scop)

### [`v4.551.0`](https://github.com/aquaproj/aqua-registry/releases/tag/v4.551.0)

[Compare Source](aquaproj/aqua-registry@v4.550.0...v4.551.0)

[Issues](https://github.com/aquaproj/aqua-registry/issues?q=is%3Aissue+milestone%3Av4.551.0) | [Merge Requests](https://github.com/aquaproj/aqua-registry/pulls?q=is%3Apr+milestone%3Av4.551.0) | <aquaproj/aqua-registry@v4.550.0...v4.551.0>

#### 🎉 New Packages

[#&#8203;58475](aquaproj/aqua-registry#58475) [mikevalstar/okq](https://github.com/mikevalstar/okq) - Fast, deterministic CLI to search and navigate Open Knowledge Format (OKF), or Obsidian style doc bundles — for humans and AI agents. Find by frontmatter, traverse the link graph, surface orphans/deadlinks [@&#8203;mikevalstar](https://github.com/mikevalstar)
[#&#8203;58468](aquaproj/aqua-registry#58468) [mekedron/wolt-cli](https://github.com/mekedron/wolt-cli) - Free & Open Source CLI for Wolt: discover venues, inspect menus and options, manage carts, and preview checkout from the terminal [@&#8203;sanchpet](https://github.com/sanchpet)

#### Fixes

[#&#8203;58618](aquaproj/aqua-registry#58618) jgm/pandoc: Install pandoc-lua and pandoc-server where available [@&#8203;scop](https://github.com/scop)
[#&#8203;58616](aquaproj/aqua-registry#58616) modem-dev/hunk: Support windows/amd64 for >= v0.12.0-beta.2 [@&#8203;elucid](https://github.com/elucid)
[#&#8203;58400](aquaproj/aqua-registry#58400) anthropics/claude-code: Install from GitHub Releases and verify [@&#8203;nicwortel](https://github.com/nicwortel)
[#&#8203;58596](aquaproj/aqua-registry#58596) kunobi-ninja/kunobi: Use GitHub release as version source [@&#8203;scop](https://github.com/scop)
[#&#8203;58597](aquaproj/aqua-registry#58597) apstndb/spannerplanviz/rendertree: Use GitHub release ver src [@&#8203;scop](https://github.com/scop)
[#&#8203;58615](aquaproj/aqua-registry#58615) apstndb/execspansql: Use GitHub release version source [@&#8203;scop](https://github.com/scop)

#### Security

[#&#8203;58423](aquaproj/aqua-registry#58423) matteo-sung/lockvet: GitHub artifact attestations config [@&#8203;scop](https://github.com/scop)
[#&#8203;58482](aquaproj/aqua-registry#58482) stefanprodan/timoni: GitHub artifact attestations config [@&#8203;scop](https://github.com/scop)
[#&#8203;58595](aquaproj/aqua-registry#58595) concourse/concourse/fly: checksum config [@&#8203;scop](https://github.com/scop)

</details>

---

### Configuration

📅 **Schedule**: (UTC)

- Branch creation
  - At any time (no schedule defined)
- Automerge
  - At any time (no schedule defined)

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever MR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this MR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this MR, check this box

---

This MR has been generated by [Mend Renovate](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4yODguMCIsInVwZGF0ZWRJblZlciI6IjQzLjI4OC4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJSZW5vdmF0ZSBCb3QiLCJhdXRvbWF0aW9uOmJvdC1hdXRob3JlZCIsImRlcGVuZGVuY3ktdHlwZTo6bWlub3IiXX0=-->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants