Skip to content

System context advertises pip and Homebrew, but both are broken in the container #74

Description

@alanbem

Problem

generate_system_context() tells Claude: "Package Managers: npm, pip, Homebrew/Linuxbrew". Verified inside a current container:

pip — Ubuntu 24.04 is PEP 668 externally-managed:

$ pip install requests
error: externally-managed-environment

Every containerized Claude that follows the system context will try pip, fail, and improvise (--break-system-packages, sudo attempts, etc.).

Homebrew — on Apple Silicon hosts the container is aarch64, and Homebrew on Linux officially supports x86_64 only: no bottles on ARM64 Linux, so most formulae build from source (very slow) or fail outright. Meanwhile the image pays the size cost of Homebrew + build-essential unconditionally.

Fix options

  1. System context accuracy (cheap, do regardless): tell Claude how to install Python packages (python3 -m venv / pipx, which could be preinstalled) and note Homebrew's ARM64 limitation — or omit brew from the tool list on ARM images
  2. Preinstall pipx and/or python3-venv so there is a working documented path
  3. Reconsider whether Homebrew earns its place in the image at all (size vs. utility on the dominant Apple Silicon platform)

Found during a full-project code review, verified live in an aarch64 container.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions