Skip to main content

kabinet

codecov PyPI version Maintenance Maintainer PyPI pyversions PyPI download month Ruff

The python client for kabinet, the Arkitekt service that manages the installable apps of a deployment: the repositories they come from, their releases and flavours, and the deployments and pods that run them. It is the successor to the port spec.

Installation

pip install kabinet

With arkitekt, pip install "arkitekt[rekuest,kabinet]" brings it in.

Usage

Every kabinet operation is a method of the Kabinet client, in a blocking and an a-prefixed async flavour (kabinet.get_pod(id), await kabinet.aget_pod(id)). Nothing is looked up ambiently.

In an arkitekt app

Add the service to your app and ask for kabinet: Kabinet; the client is injected by annotation. Pods, deployments, releases, approvals, definitions and flavours travel between actions by id (@kabinet/pod, @kabinet/deployment, @kabinet/release, @kabinet/approval, @kabinet/definition, @kabinet/flavour), so an action can take and return them directly:

from arkitekt import App, run
from kabinet import Kabinet, kabinet_service
from kabinet.api.schema import Pod

app = App("pod-status", "0.1.0", services=[kabinet_service])


@app.action
def pod_status(pod: Pod, kabinet: Kabinet) -> str:
    """Pod Status

    Fetches the current status of a pod.
    """
    return kabinet.get_pod(pod.id).status.value


if __name__ == "__main__":
    run(app)

From a script

from arkitekt import easy
from kabinet import kabinet_service

with easy("my-script", kabinet_service) as kabinet:
    repo = kabinet.create_github_repo(
        name="A new repo",
        identifier="jhnnsrs/kabinet:main",
    )
    print(repo)  # the repo with all the app images found in it

Testing

uv run pytest -m "not integration"   # fast unit layer: no docker, <1s
uv run pytest                        # full suite: spins the dokker compose stack

The unit layer proves the wire contract through a rath AsyncMockLink (camelCase aliases, @oneOf ordering variants, the six-kind selector union, the PodEvent subscription shape) and the arkitekt service wiring via a hot-plugged fakts.testing.TestingFakts. The integration-marked tests run the same operations against the composed server image; until a new-generation jhnnsrs/kabinet:next is pushed, point them at a locally built image with KABINET_SERVICE_IMAGE=next-kabinet:latest uv run pytest.

See RELEASING.md for how versions are cut.

Metadata

Release files for kabinet 5.0.1

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

Source distribution (sdist)

Source distribution for kabinet 5.0.1
File Size Uploaded
kabinet-5.0.1.tar.gz 75.6 kB Details

Built distribution (wheel)

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

Total release size: 152.7 kB

Release files / kabinet-5.0.1.tar.gz

Download URL kabinet-5.0.1.tar.gz
Size 75.6 kB
Tags Source
SHA-256 checksum
How to use checksums
7ae8bd3477da3d97c55d4b0b4565d5585f44d8d07115c089970048c6b590993d
BLAKE2b-256 checksum
How to use checksums
f17bc411162957abc5ea2fa62d047535e10de1c1754474d7b198218ef23fa127
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.23 {"installer":{"name":"uv","version":"0.12.23","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / kabinet-5.0.1-py3-none-any.whl

Download URL kabinet-5.0.1-py3-none-any.whl
Size 77.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
42a84d90be9b09ce6e02c9b9cff68160ad6efc93c9b67b3f4a0ab67ac9b82cf3
BLAKE2b-256 checksum
How to use checksums
ee1dd201a1165a9f7ac65e39d367196e24f2076e63a489af328b9c55b99dfa47
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.23 {"installer":{"name":"uv","version":"0.12.23","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release history Release notifications | RSS feed

5.2.0

2 release files

5.1.0

2 release files

This release

5.0.1 This release

2 release files

5.0.0

2 release files

4.1.0

2 release files

4.0.0

2 release files

3.0.2

2 release files

3.0.1

2 release files

3.0.0

2 release files

2.0.1

2 release files

2.0.0

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

0.11.4

2 release files

0.11.3

2 release files

0.11.2

2 release files

0.11.1

2 release files

0.10.0

2 release files

0.9.0

2 release files

0.8.0

2 release files

0.7.0

2 release files

0.6.0

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.46

2 release files

0.1.45

2 release files

0.1.44

2 release files

0.1.43

2 release files

0.1.42

2 release files

0.1.41

2 release files

0.1.40

2 release files

0.1.38

2 release files

0.1.37

2 release files

0.1.36

2 release files

0.1.35

2 release files

0.1.34

2 release files

0.1.33

2 release files

0.1.32

2 release files

0.1.31

2 release files

0.1.30

2 release files

0.1.29

2 release files

0.1.28

2 release files

0.1.27

2 release files

0.1.26

2 release files

0.1.25

2 release files

0.1.24

2 release files

0.1.23

2 release files

0.1.22

2 release files

0.1.21

2 release files

0.1.20

2 release files

0.1.19

2 release files

0.1.18

2 release files

0.1.17

2 release files

0.1.15

2 release files

0.1.14

2 release files

0.1.13

2 release files

0.1.12

2 release files

0.1.11

2 release files

0.1.10

2 release files

0.1.9

2 release files

0.1.8

2 release files

0.1.7

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

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