feat(installer): add lean bootstrap planner#494
Closed
kvandre12-commits wants to merge 2 commits into
Closed
Conversation
kvandre12-commits
force-pushed
the
feature/lean-bootstrap-installer
branch
from
June 20, 2026 21:01
b70ffbe to
d6543a2
Compare
Owner
|
Can you add instructions to install / run Code Puppy on native Android / Termux in the README.md using this new system? |
Author
|
Closing this one as superseded by #496. #494 captured the lean bootstrap planner direction, but #496 is now the cleaner upstream lane because it keeps that Android/Termux bootstrap intent while also fixing the actual native dependency blockers found by real installs:
Follow-up / active PR: #496 |
Author
|
Superseded by #496, which carries the lean Android/Termux bootstrap path plus the native dependency fixes needed for a minimal working Code Puppy install. |
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.
Summary
This PR addresses the dependency-bloat problem on constrained environments (especially Android/Termux) by moving the decision point from runtime fallback handling to install-time bootstrap planning.
Instead of importing the full runtime path and then gracefully degrading after unsupported dependencies have already been attached, this introduces a lightweight bootstrap entrypoint (
code-puppy-bootstrap) that detects the target environment first, selects an install profile, and emits a lean install/reattach plan before optional capabilities are attached.Fixes
What's Changed
code_puppy/bootstrap.pyas a lightweight bootstrap CLI entrypoint.code_puppy/bootstrap_profiles.pyfor environment detection and profile-based planning.coreandroid-termux-leandesktop-browserdeveloper-fullextras_addextras_removenotespackage_namecode-puppy-bootstraptests/test_bootstrap.pycovering:Design Notes
The bootstrap path is intentionally stdlib-only and decoupled from
cli_runner, so installation planning can happen without pulling in the heavier runtime CLI import graph.That separation is the main design goal of this change:
Validation
Local validation for this PR slice:
ruff format --check .ruff check .python -m pytest tests/test_bootstrap.py -q -o addopts=''(8 passed)Additional regression coverage previously re-run against this changeset also passed locally:
tests/test_cli_runner.pytests/test_cli_runner_coverage.pytests/test_tools_registration.pytests/test_tools_init_full_coverage.pytests/test_uvx_detection.pyNote on Current Upstream Test Noise
While doing a full local
python -m pytest tests/validation on the current checkout, there are unrelated failures outside this PR's change surface:tests/plugins/test_ollama_plugin.pyOpenAIProvideroncode_puppy.plugins.ollama.register_callbackstests/plugins/test_shell_safety_callbacks.pyget_global_model_nameoncode_puppy.plugins.shell_safety.register_callbacksThese failures appear unrelated to the bootstrap installer changes in this PR and look like existing test/module drift in other plugin areas.
Why This Approach
This change prefers install-time capability planning over post-install graceful degradation.
That gives constrained environments a cleaner default path: