Skip to main content

kavacha

Install

pip install kavacha
pip install "kavacha[window]"
pip install "kavacha[macapp]"
pip install "kavacha[windows]"

The extras add native-window support and platform freezer dependencies.

Describe the app

from kavacha import App, tree, doc_types, mypyc_modules

app = App(
    name='Demo',
    entry='demo_app.py',
    version='1.2.3',
    icon='assets/Demo.icns',
    packages=['demo', 'fasthtml', 'uvicorn', 'numpy'],
    includes=['demo.cli', *mypyc_modules()],
    grafted=['apsw', 'playwright'],
    data=tree('demo/static', 'demo/static'),
    extras=['desktop'],
    doc_types=doc_types(['.py', '.rs', '.md']),
)
app.py2app_options()

One App specification supplies both platform freezers. Explicit packages and modules cover imports a freezer cannot discover.

Build

from kavacha import build, check

check(app, root)
build(app, root, setup_py='packaging/macos/setup.py')

build uses a compatible interpreter, installs pinned requirements from uv.lock, refuses to replace a running bundle unless forced, and records the source commit.

After freezing

from kavacha import finish

finish(bundle, app)

finish grafts archive-incompatible packages, removes unreachable archive copies, links duplicate files, mends Frameworks libraries two sources share a basename for, and installs the modern icon before signing.

Icons

from kavacha.icons import icons_for

icons_for('assets/logo.png', 'assets', 'Demo')

A square image of at least 512 pixels produces platform and web icon assets. Invalid sources are rejected rather than upscaled.

Window

from kavacha.window import run_shell, shell_ready

ok, why = shell_ready()
run_shell('http://127.0.0.1:8000', title='Demo', size='1440x900')

run_shell opens a pywebview window over a loopback server. The host supplies menus and workspace callbacks.

Status

The spec, build driver, bundle surgery and icons are covered by tests that run anywhere. The window and menus are ported working code, but the platform they matter on is not one CI can exercise here — treat that module as needing a real run on macOS before you rely on it.

Metadata

Release files for kavacha 0.0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for kavacha 0.0.3
File Size Uploaded Provenance Actions
kavacha-0.0.3.tar.gz 26.8 kB Without provenance Details for kavacha-0.0.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for kavacha 0.0.3
File Interpreter ABI Platform Actions
kavacha-0.0.3-py3-none-any.whl Python 3 none any Details for kavacha-0.0.3-py3-none-any.whl

Total release size: 57.5 kB

Release files / kavacha-0.0.3.tar.gz

Download URL kavacha-0.0.3.tar.gz
Size 26.8 kB
Tags Source
SHA-256 checksum
How to use checksums
25b78fab91b1279844401a2048e5c7258fc965e6f24b026c3ed18fd06ed9b562
BLAKE2b-256 checksum
How to use checksums
1b694f5c4f4414528113a3255930b39a5d26cd0545eff70e1a115399cc5f3ce7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.6

Release files / kavacha-0.0.3-py3-none-any.whl

Download URL kavacha-0.0.3-py3-none-any.whl
Size 30.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
41379cf9ac329fd6bbe5bf23d1fb6f7118baeb62c4f8f88f7004fe572e44452f
BLAKE2b-256 checksum
How to use checksums
286ab670fa8a2f38dc0e11b36b9f79a1c67ae75e7f5ffe6f6236f03beae9f062
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.6

Security for kavacha 0.0.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page