Skip to main content

A package for interacting with the concord4ws server.

Project description

concord4ws-py

Python library for interfacing with Concord4WS https://github.com/JoeyEamigh/concord4ws. This library depends on the Concord4WS server.

Installation

pip install concord4ws

Usage

import asyncio
from concord4ws import Concord4WSClient


async def main():
    client = Concord4WSClient("127.0.0.01", 8080)

    if await client.test_connect():
        print("Connected")
    else:
        print("Not Connected")

    zoneCallback = lambda: print(client._state.zones)
    partitionCallback = lambda: print(client._state.partitions)

    await client.connect()

    print("Ready!")

    for zone in client._state.zones:
        client.register_callback(zone, zoneCallback)

    for partition in client._state.partitions:
        client.register_callback(partition, partitionCallback)

    await asyncio.futures.Future()


asyncio.run(main())

Development Setup

python -m venv .venv
source .venv/bin/activate
pip install --upgrade pip
pip install -r requirements.txt

Project details


Download files

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

Source Distribution

concord4ws-0.3.1.tar.gz (5.9 kB view details)

Uploaded Source

Built Distribution

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

concord4ws-0.3.1-py3-none-any.whl (7.1 kB view details)

Uploaded Python 3

File details

Details for the file concord4ws-0.3.1.tar.gz.

File metadata

  • Download URL: concord4ws-0.3.1.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.12.0 Linux/6.12.10-arch1-1

File hashes

Hashes for concord4ws-0.3.1.tar.gz
Algorithm Hash digest
SHA256 3282a06137f9bf3644a7e9a61179dbec3a6e75b63e79712d09a1029a1dad4dde
MD5 79b5fb48d03173865e87618bc2b97d83
BLAKE2b-256 0985ca9236179be1c4e1a8151cda3e98ae9938abc5287e8da8a45d9d7cd60f13

See more details on using hashes here.

File details

Details for the file concord4ws-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: concord4ws-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 7.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.0.1 CPython/3.12.0 Linux/6.12.10-arch1-1

File hashes

Hashes for concord4ws-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 c4dc9e6b96efb8bda0586845e9580428d19f59f02035c9e2716a463a0acd84b0
MD5 0a4d0b444fef5d7e8b854ada5f3011f2
BLAKE2b-256 18bbc4ff6e43bfd8e384275b50186c755cc64bbce459e392a1476d1ac47e31bf

See more details on using hashes here.

Supported by

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