--- id: charmcraftlocal version: "0.4.0" license: unclear license_treatment: unclear maintenance: active --- # charmcraftlocal — Pack charms with local Python package dependencies License: unclear · Maintenance: active · Downloads: 84.2K/mo ## What it is and what it does charmcraftlocal is a build-time helper for Juju charm projects that use Poetry to manage Python dependencies. It solves the problem that charmcraft can only access files in the charm's own directory during packing, preventing it from directly including local Python packages from sibling directories in a monorepo. The tool searches a charm's pyproject.toml for local dependencies, copies them into the charm directory, and updates Poetry's lock files so the build succeeds. It provides two main commands: `ccl pack` copies local packages and calls charmcraft, while `ccl update-lock` updates Poetry metadata during the build process. For projects with multiple charms sharing code, it also offers `ccl mirror` to create separate git repositories that meet standard tooling expectations, using git-filter-repo to preserve history while keeping pyproject.toml and poetry.lock in sync. Use it for: - Build a Juju charm in a monorepo where multiple charms share a common Python library in a sibling directory. - Automate charm packing in CI/CD pipelines that expect charmcraft pack to work without manual dependency copying. - Create mirror repositories for individual charms that maintain commit history while isolating local dependencies. - Develop charms with Poetry-managed dependencies that reference local packages via path dependencies. - Integrate charm builds into existing tooling that expects one charm per git repository at the root. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Packs Juju charms with local Python package dependencies by copying them into the charm directory and updating Poetry lock files before building. Yes, if you are building Juju charms with Poetry in a monorepo or multi-charm structure. The tool directly solves a real constraint of charmcraft and is actively maintained. However, verify the license status before use in proprietary contexts, and confirm your charm project uses Poetry—it is not a general-purpose charm builder. ## Install pip install charmcraftlocal uv add charmcraftlocal poetry add charmcraftlocal ## Installing charmcraftlocal Before you install: Low friction install via pipx or uv. Active maintenance with recent releases. Six runtime dependencies (pyyaml, requests, rich, tomli, typer, charm-refresh-build-version) are all standard utilities with broad ecosystem support. License in practice: License status is unclear—no SPDX identifier or raw license text is available. Verify the actual license before using in proprietary or restricted contexts. Quickstart: pipx install charmcraftlocal charmcraftlocal pack # or within charmcraft.yaml: charmcraftlocal update-lock -v Requires Python >=3.10. Designed for charms managed with Poetry; non-Poetry charms are not currently supported. Verify before relying: - Whether the package works with charm projects outside monorepo structures or single-charm repositories. - Performance characteristics when handling large numbers of local dependencies or deeply nested package structures. - Compatibility with Poetry versions beyond what the description implies. ## Package facts - License: not declared (unclear) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 84.2K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags charm packaging with local dependencies, juju charm build local python packages, poetry local package charm packing, charmcraft local dependency management, charm monorepo shared code packaging, juju-charm, poetry-integration, monorepo-tooling [View on SkillFed](https://skillfed.io/packages/charmcraftlocal) · [View on PyPI](https://pypi.org/project/charmcraftlocal/)