fix: the pin is not a floor, and stop demanding CMake and cpanm - #51
Merged
Conversation
Three things made `--system` unusable outside a machine that was already pinned, which is every stock Mac: The version gate I added compared against the mise pin, so system Perl 5.40 was refused against a 5.44 pin and Ruby 3.3 against 4.0.6, even though both build the bindings perfectly well. The gate now fails only below the version the port itself declares (go.mod, Cargo.toml rust-version, requires-python, the gemspec, composer.json, MIN_PERL_VERSION, cmake_minimum_required) and merely says something between that and the pin. Bun keeps a real floor of 1.4.0, because 1.3 cannot parse a lockfileVersion 2 bun.lock. CMake is a build tool for the native binding, not the runtime `--system` is about, so when the host has none and mise is installed the pinned one is borrowed rather than refusing to run. Without mise the message now names the actual command to run on that platform. macOS ships Perl but no cpanm, which stopped `--system perl` before it built anything. cpanm is now fetched into the private demo cache, the same place FFI::Platypus already went. Nothing global is touched. Verified on a box whose system Perl (5.40.1) and Ruby (3.3.8) are both below the pins: both now build the native binding and render the dashboard with no mise runtime. A new test checks the declared floors against the ports' own manifests so they cannot drift. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TbGYCRHZsZUsQwRCLafhMF
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
--systemwas unusable on any machine that was not already pinned, which is every stock Mac. Reported as "I have to use--mise perlalways".Three separate causes.
The pin was treated as a floor
The version gate in #50 compared the resolved tool against the mise pin. So system Perl 5.40 was refused against a 5.44 pin, and Ruby 3.3 against 4.0.6, even though both build these bindings perfectly well. That is a regression from #50 and it defeated the point of the flag.
The gate now fails only below the version the port itself declares it needs, and merely mentions anything between that floor and the pin:
Floors come from each port's own manifest:
ports/go/go.mod(1.22),Cargo.tomlrust-version(1.75),requires-python(3.10),hqtui.gemspec(3.1),composer.json(8.1),Makefile.PLMIN_PERL_VERSION(5.20),cmake_minimum_required(3.20). Bun keeps a real floor of 1.4.0, since 1.3 genuinely cannot parse alockfileVersion: 2bun.lock— the bug #50 was opened for, still caught:CMake was mandatory
CMake is a build tool for the native binding, not the language runtime
--systemis about, and the C++ compiler still comes from the host. When the host has no CMake and mise is installed, the pinned one is now borrowed with a note instead of refusing to run. With no mise, the message names the actual command for that platform (brew install cmakeon Darwin).macOS ships Perl but no cpanm
--system perldied atcpanm: not foundbefore building anything. The standalone installer is now fetched into the private demo cache, the same placeFFI::Platypusalready went. Nothing global is touched, and the failure message no longer asks for a manual step.Verified
On a box whose system Perl (5.40.1) and Ruby (3.3.8) are both below the pins, with no CMake and no cpanm on
PATH:--system perlborrows the pinned CMake, fetches cpanm, builds FFI::Platypus and the native binding, and renders the dashboard.--system rubyrenders the dashboard.--system typescriptwith Bun 1.3.14 still fails, with the message naming both versions.15/15 updater tests,
sh -n,dash -n, andshellcheck -s sh(only the pre-existing SC2016 at theperl -MConfigline).test_declared_floors_match_the_ports_own_manifestsreads the floors back out ofdemo.shand compares each against the manifest that states it, so a port raising its requirement cannot leave the launcher starting a build that cannot succeed.🤖 Generated with Claude Code
https://claude.ai/code/session_01TbGYCRHZsZUsQwRCLafhMF