fix(ruby): require build revision releases#10428
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
✅ Files skipped from review due to trivial changes (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughRefactors GitHub release API to distinguish numeric build-revision tags, integrates it into RubyPlugin with helpers and early-exit logic for missing build-revision releases, extends unit tests, and documents the behavior in Ruby and mise-lock reference docs. ChangesRuby Precompiled Build Revision
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Comment |
Greptile SummaryThis PR tightens the default
Confidence Score: 5/5Safe to merge; the change is well-scoped to the default jdx/ruby source and custom sources are unaffected. All changed logic is covered by new unit tests. The No files require special attention. Important Files Changed
Reviews (2): Last reviewed commit: "fix(ruby): require build revision releas..." | Re-trigger Greptile |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@docs/lang/ruby.md`:
- Around line 88-95: The lockfile refresh instructions in the Ruby documentation
are unclear and potentially misleading about how much needs to be removed.
Currently the text says to remove "the Ruby entry (or the relevant platform
URL)" but since the Ruby lockfile code scans every stored platform entry,
removing just one platform URL is insufficient and will leave the old revision
pinned. Update the instructions to explicitly state that users must either
delete the entire Ruby entry from mise.lock, or delete every Ruby platform URL
entry (not just one platform URL), before regenerating the lockfile with mise
lock ruby and mise install --force ruby.
In `@src/plugins/core/ruby.rs`:
- Around line 620-623: The current code infers the absence of a build revision
release by comparing tag_name to version, but
`get_release_with_build_revision()` can fall back to the base tag even when a
build-revision release exists. Modify `get_release_with_build_revision()` to
explicitly report whether a build-revision release was actually found (rather
than just a fallback to the base tag), then update the conditional check in
`Self::source_requires_build_revision(repo)` to use this explicit status instead
of inferring it from the tag name comparison.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 4bb41242-afed-4632-b28f-022b18768d01
📒 Files selected for processing (3)
docs/dev-tools/mise-lock.mddocs/lang/ruby.mdsrc/plugins/core/ruby.rs
3e99e52 to
4a85a47
Compare
Hyperfine Performance
|
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2026.6.7 x -- echo |
19.7 ± 1.0 | 17.9 | 24.9 | 1.00 |
mise x -- echo |
20.6 ± 1.4 | 18.5 | 33.8 | 1.05 ± 0.09 |
mise env
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2026.6.7 env |
19.3 ± 1.0 | 17.4 | 25.1 | 1.00 |
mise env |
19.8 ± 1.0 | 18.0 | 24.8 | 1.03 ± 0.07 |
mise hook-env
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2026.6.7 hook-env |
20.1 ± 0.9 | 18.4 | 23.6 | 1.00 |
mise hook-env |
20.5 ± 0.9 | 18.7 | 25.8 | 1.02 ± 0.06 |
mise ls
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2026.6.7 ls |
16.8 ± 0.8 | 15.4 | 20.1 | 1.00 |
mise ls |
17.4 ± 0.9 | 15.6 | 21.1 | 1.03 ± 0.07 |
xtasks/test/perf
| Command | mise-2026.6.7 | mise | Variance |
|---|---|---|---|
| install (cached) | 137ms | 137ms | +0% |
| ls (cached) | 60ms | 60ms | +0% |
| bin-paths (cached) | 65ms | 66ms | -1% |
| task-ls (cached) | 125ms | 127ms | -1% |
Summary
jdx/rubyprecompiled source to resolve numeric build revision tags instead of using the floating base release tagContext
jdx/rubypublishes immutable build revision releases like3.3.11-1alongside the floating base release. Since everyjdx/rubyprecompiled Ruby version should have a build revision, mise should not lock or install the base release tag for that default source.Validation
cargo fmt --checkgit diff --checkcargo test ruby_build_revisioncargo test test_ruby_default_precompiled_source_requires_build_revisioncargo test test_build_revisionNote
Medium Risk
Changes Ruby install/lock resolution for the default precompiled source; versions that only have a base tag may stop using precompiled binaries until a build revision exists, while custom sources are unchanged.
Overview
Default
jdx/rubyprecompiled installs and lock URLs no longer target the floating base release tag (e.g.3.3.11). Resolution prefers the highest numeric build revision (3.3.11-1,3.3.11-2, …) and aborts the precompiled path when no such tag exists, so mise can fall back to source compile instead of locking a mutable base asset.GitHub release selection gains
get_release_with_build_revision_statusandpick_best_numeric_build_revision, which report whether a numeric-Nsuffix was found; the Ruby plugin applies that only when the precompiled source is the defaultjdx/rubyrepo—customruby.precompiled_urlGitHub sources still allow the old base-tag fallback.Docs drop treating the base release as an expected lockfile revision and state that mise uses build-revision tags for
jdx/ruby, with slightly clearer lockfile refresh steps.Reviewed by Cursor Bugbot for commit 4a85a47. Bugbot is set up for automated code reviews on this repo. Configure here.
Summary by CodeRabbit
mise.lockpins a specific build-revision tag (e.g.,3.3.11-1,3.3.11-2), how “latest available” behavior works without the lockfile, and how to interpret the corresponding release URL paths.