Skip to main content

knxyz

KNXyz for Python: KNXnet/IP clients and .knxproj loading.

Install

pip install knxyz

Host values

An omitted item composes as the row's zero default, so {} asks for every declared item at its zero default and write(ga, {}, "9.001") transmits 0.0 degree C. An explicit None is a different request: where the row declares an invalid marker, None asks for that marker.

A host value the document cannot carry faithfully is refused before any document, frame or socket work exists, so a refused call sends nothing at all. None, bool, int, a finite float, str, list, tuple and dict with string keys are carried, including a subclass that stores no instance state of its own. A set, bytes, a Decimal, a non-dict Mapping, an arbitrary object, a dict carrying a key that is not a string, a subclass carrying instance state the document has nowhere to put and a subclass whose class will not say where its instance state is are refused with a KnxError whose code is host/non-finite-number, host/unrepresentable-value, host/circular-structure or host/value-too-complex.

Errors

A refused KNX operation raises a KnxError carrying a code, a hierarchical path whose first segment names the authority that refused and picks the subclass raised. A mistake in the shape of an options object is a different layer and a different class: it raises a plain ValueError naming the key, because the remedy is a fix at the call site rather than a branch on a wire code.

Threads

The address helpers and .knxproj loading hold no state of their own and are callable from any thread. A client object serializes its own state: the native tunnel and routing clients each guard their transport and their monitor subscription with their own locks, so calls on one client from several threads interleave rather than race, and a second monitor_next while one is pending is refused rather than admitted. The GIL is released around every call that blocks on the transport, so a blocked send, monitor wait or close does not stop other Python threads. The value and option judgements run before that release, which is why a refused call is refused without touching a socket.

.knxproj loading

from knxyz import load_knxproj

project = load_knxproj("project.knxproj")
print(len(project.group_addresses))

The knxyz.io documentation tracks the source in the repository. A published version can be built from different source under the same version number, so those pages may describe API this package version does not carry.

Documentation: https://knxyz.io
Repository: https://github.com/goznauk/KNXyz

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

knxyz-0.0.8.tar.gz (308.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

knxyz-0.0.8-cp312-cp312-manylinux_2_34_x86_64.whl (908.9 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.34+ x86-64

File details

Details for the file knxyz-0.0.8.tar.gz.

File metadata

  • Download URL: knxyz-0.0.8.tar.gz
  • Upload date:
  • Size: 308.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for knxyz-0.0.8.tar.gz
Algorithm Hash digest
SHA256 b937e159d71a13dc6eaf7408d82898fb732e84a9a56463c66c27fd13f4c0967a
MD5 bfb6e61735b9afb04a8a15203ae4ca4b
BLAKE2b-256 50562adb692097fe751cb91692bcd9ba845afa2582fb50efeb64e70551502a81

See more details on using hashes here.

Provenance

The following attestation bundles were made for knxyz-0.0.8.tar.gz:

Publisher: publish-pypi.yml on goznauk/KNXyz

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file knxyz-0.0.8-cp312-cp312-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for knxyz-0.0.8-cp312-cp312-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 d6005bced85b6a4ceefc4a00a6ffd6537bbe7d1f54c3fd1395dbec2064e8a767
MD5 f716ef6b4871004c89f0bd95f424d49c
BLAKE2b-256 2eec643b1ff093aae7ddef018ef9de2438028232d94c5172c5f1e6ff75dc75c7

See more details on using hashes here.

Provenance

The following attestation bundles were made for knxyz-0.0.8-cp312-cp312-manylinux_2_34_x86_64.whl:

Publisher: publish-pypi.yml on goznauk/KNXyz

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.0.8 This release

2 files

0.0.6

2 files

0.0.5

2 files

0.0.4

2 files

0.0.3

2 files

0.0.2

2 files

0.0.1

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page