Skip to content

The native Claude Code binary can be missing from container images (interrupted download) #79

Description

@kqr

The native Claude Code binary is of non-trivial size (> 200 MB) and is listed as an optional dependency to the NPM package. This means NPM will try to download it, but if the download is interrupted, the container image build will still finish successfully. However, when the user tries to run Leash, they will get the error

Error: claude native binary not installed.

Either postinstall did not run (--ignore-scripts, some pnpm configs)
or the platform-native optional dependency was not downloaded
(--omit=optional).

Run the postinstall manually (adjust path for local vs global install):

node node_modules/@anthropic-ai/claude-code/install.cjs

Or reinstall without --ignore-scripts / --omit=optional.

I solved it by building the container again, but the Makefile could benefit from a verification step where it fails if the Claude Code binary is missing from the container image.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions