Skip to content

fix(go): filter out version "1" from available versions#7871

Merged
jdx merged 2 commits intomainfrom
fix/go-version-1
Jan 28, 2026
Merged

fix(go): filter out version "1" from available versions#7871
jdx merged 2 commits intomainfrom
fix/go-version-1

Conversation

@jdx
Copy link
Copy Markdown
Owner

@jdx jdx commented Jan 28, 2026

Summary

  • Filter out Go version "1" from the available versions list
  • This version corresponds to go1 tag which is not installable via modern download URLs

Problem

Go 1.0 was released with the tag go1 (no minor/patch version), so "1" appears as a literal version. When users specify go = "1" expecting the latest 1.x.y, version resolution finds "1" as an exact match and tries to download go1.darwin-arm64.tar.gz which doesn't exist.

Test plan

# Before fix:
$ mise ls-remote go | head -3
1
1.0.1
1.0.2

$ mise install go@1 --dry-run
mise go@1   ⇢ would install  # Tries to download non-existent URL

# After fix:
$ mise ls-remote go | head -3
1.0.1
1.0.2
1.0.3

$ mise install go@1 --dry-run
mise go@1.25.6   ⇢ would install  # Resolves to latest 1.x

Fixes #7861

🤖 Generated with Claude Code


Note

Centralizes version filtering and removes non-installable/pre-release Go tags from listings.

  • Adds is_valid_version to exclude "1" and (beta|rc) tags
  • Applies filter in both slow (GitHub tags with dates) and fast (git ls-remote) paths of _list_remote_versions

Written by Cursor Bugbot for commit 1b4e9b9. This will update automatically on new commits. Configure here.

Go 1.0 was released with the tag `go1` (no minor/patch version), so "1"
appears as a literal version. When users specify `go = "1"` expecting
the latest 1.x.y, version resolution finds "1" as an exact match and
tries to download `go1.darwin-arm64.tar.gz` which doesn't exist.

Filter out "1" since it's not installable via modern download URLs.

Fixes #7861

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings January 28, 2026 15:00
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes an issue where Go version "1" (corresponding to the legacy go1 tag) appears in the available versions list but cannot be installed via modern download URLs. When users specify go = "1" expecting the latest 1.x version, the resolver incorrectly matches the literal "1" version and attempts to download a non-existent file.

Changes:

  • Added filtering to exclude version "1" from available Go versions in both the GitHub tags and HTML fallback listing methods

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

Comment thread src/plugins/core/go.rs Outdated
Addresses PR feedback to reduce code duplication. The version filtering
logic (excluding "1" and beta/rc versions) was duplicated in both the
slow and fast paths of _list_remote_versions.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@jdx jdx enabled auto-merge (squash) January 28, 2026 15:16
@jdx jdx merged commit 29dd9a4 into main Jan 28, 2026
35 checks passed
@jdx jdx deleted the fix/go-version-1 branch January 28, 2026 15:25
@github-actions
Copy link
Copy Markdown

Hyperfine Performance

mise x -- echo

Command Mean [ms] Min [ms] Max [ms] Relative
mise-2026.1.8 x -- echo 19.1 ± 0.2 18.7 21.4 1.00
mise x -- echo 19.5 ± 1.1 18.9 36.6 1.02 ± 0.06

mise env

Command Mean [ms] Min [ms] Max [ms] Relative
mise-2026.1.8 env 18.5 ± 0.4 18.1 24.7 1.00
mise env 19.0 ± 0.7 18.4 25.3 1.03 ± 0.04

mise hook-env

Command Mean [ms] Min [ms] Max [ms] Relative
mise-2026.1.8 hook-env 18.8 ± 0.3 18.3 19.8 1.00
mise hook-env 19.1 ± 0.3 18.6 20.3 1.02 ± 0.02

mise ls

Command Mean [ms] Min [ms] Max [ms] Relative
mise-2026.1.8 ls 16.7 ± 0.2 16.2 18.5 1.00
mise ls 17.1 ± 0.4 16.6 20.2 1.03 ± 0.03

xtasks/test/perf

Command mise-2026.1.8 mise Variance
install (cached) 108ms 110ms -1%
ls (cached) 65ms 65ms +0%
bin-paths (cached) 69ms 69ms +0%
task-ls (cached) 2261ms ✅ 288ms +685%

✅ Performance improvement: task-ls cached is 685%

mise-en-dev added a commit that referenced this pull request Jan 28, 2026
### 🚀 Features

- **(doctor)** add backend mismatch warnings by @jdx in
[#7847](#7847)
- **(http)** add rename_exe support for archive extraction by @jdx in
[#7874](#7874)
- **(http)** send x-mise-ci header for CI environment tracking by @jdx
in [#7875](#7875)
- **(install)** auto-install plugins from [plugins] config section by
@jdx in [#7856](#7856)
- **(registry)** add vercel by @mikecurtis in
[#7844](#7844)
- **(task)** support glob patterns in task_config.includes by @jdx in
[#7870](#7870)
- **(task)** add task templates for reusable task definitions by @jdx in
[#7873](#7873)

### 🐛 Bug Fixes

- **(backend)** change registry mismatch log from info to debug by @jdx
in [#7858](#7858)
- **(ci)** use squash merge for auto-merge-release workflow by @jdx in
[7e5e71e](7e5e71e)
- **(ci)** remove --auto flag to merge immediately when CI passes by
@jdx in
[23ed2ed](23ed2ed)
- **(github)** select platform-matching provenance file for SLSA
verification by @jdx in [#7853](#7853)
- **(go)** filter out version "1" from available versions by @jdx in
[#7871](#7871)
- **(install)** skip CurDir components when detecting archive structure
by @jdx in [#7868](#7868)
- **(pipx)** ensure Python minor version symlink exists for postinstall
hooks by @jdx in [#7869](#7869)
- **(registry)** prevent duplicate -stable suffix in Flutter download
URLs by @jdx in [#7872](#7872)
- **(task)** pass env to usage parser for env-backed arguments by @jdx
in [#7848](#7848)
- **(task)** propagate MISE_ENV to child tasks when using -E flag by
@jdx in
[06ee776](06ee776)
- **(vfox-dotnet)** use os.execute() to fix Windows installation by
@prodrigues1912 in [#7843](#7843)

### 📚 Documentation

- update cache-behavior with env_cache information by @jdx in
[#7849](#7849)

### ◀️ Revert

- remove task inheritance from parent configs in monorepos by @jdx in
[#7851](#7851)
- Revert "fix(ci): remove --auto flag to merge immediately when CI
passes" by @jdx in
[0606187](0606187)

### 📦 Registry

- add mago
([aqua:carthage-software/mago](https://github.com/carthage-software/mago))
by @scop in [#7845](#7845)

### Chore

- **(ci)** auto-merge release branch into main daily at 4am CST by @jdx
in [#7852](#7852)

### New Contributors

- @mikecurtis made their first contribution in
[#7844](#7844)
- @prodrigues1912 made their first contribution in
[#7843](#7843)
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