Repository navigation
Conversation
The wrapper ran `mise x <package> -- <bin>`, which resolves <bin> on PATH. When ~/.local/bin comes before ~/.local/share/mise/installs/<tool>/latest (mise only prepends the install dir if it is not already on PATH, so an existing later entry keeps its position), <bin> resolves to the wrapper itself and it forks forever. Interactive shells never hit this because mise activation puts the install dir first. Non-shell launchers do: T3 Code derives its server PATH from a login shell with ~/.local/bin first, so its `claude --version` probe spun until its 4s timeout and Claude Code showed as not installed. Pass the absolute path from `mise which` to `mise x` instead, keeping the tool environment mise x sets up. Claude-Session: https://claude.ai/code/session_01Er7PXFnS9TZEM4ahK184Dt
|
This is a less robust duplicate of #8692 It also lacks a migration and tests. |
|
had same issue, fixed same way. |
|
Reviewed by Claude Opus 5.5 by reading the change. The pull request wasn't run on a worker. The second opinion (Codex Medium) didn't run because today's review quota is spent, so only one reviewer looked at this. The diagnosis is right. With Seven other open pull requests fix the same loop: #8692, #9583, #13090, #13470, #13614, #13677 and #13769. I recommend #8692 over this one, for three reasons:
This one also adds no test, and #8692 adds I didn't verify this pull request on a worker, because the fix it would ready is #8692's. Choosing between the competing fixes is the maintainer's call, so this waits on them. |
Problem
The wrapper generated by
bin/omarchy-mise-installruns:mise xresolves$binvia PATH. If~/.local/binappears before~/.local/share/mise/installs/<tool>/latest,$binresolves to the wrapper itself and it re-executes forever. mise only prepends the install dir when it is not already on PATH — if the dir is already present further down, it keeps its position, so~/.local/bin/claudekeeps winning.Interactive shells never see this:
mise activateputs the install dir first. Non-shell launchers (Electron apps,.desktopentries, systemd units) do.Concrete case: T3 Code cannot detect Claude Code
T3 Code spawns
claude --version(4 s timeout) to detect the Claude Agent CLI. Its server process derives PATH from a login shell, which on Omarchy comes out as:claude→~/.local/bin/claude(the wrapper) →mise x claude -- claude→~/.local/bin/claude→ … The probe spins, printingmise ~/.config/mise/config.toml tools: [email protected]thousands of times, until T3 kills it. Its trace log shows:and the UI reports Claude as not installed. Same applies to
codexand every other wrapper.Reproduce
Fix
Hand
mise xthe absolute path frommise whichinstead of a bare name, so no PATH lookup happens.mise xis kept so the tool environment it sets up (e.g.nodefor npm-backed packages) is unchanged.Verified with the exact T3 Code PATH: old form loops until timeout (rc=124), new form answers in ~12 ms; T3 Code then detects Claude Code normally.
mise whichalso resolvescodexandgh(bin name ≠ package name) correctly.https://claude.ai/code/session_01Er7PXFnS9TZEM4ahK184Dt