Skip to main content

A library for the cattle drive protocol

Project description

almabtrieb

This is a client library for the CattleDrive protocol as used by cattle_grid. This protocol is still somewhat in development.

This library enables one to create applications using cattle_grid as a middle ware to connect to the Fediverse. Examples:

Supported protocols

Currently, supported are connection strings starting with amqp, amqps, mqtt, mqtts, ws, and wss.

  • MQTT 5
  • AMQP, I think 0.9.1 as supported by RabbitMQ

Authentication is relegated to the underlying protocol.

Development

Run tests with

uv run pytest

This will lead to a lot of skipped tests. By running

uv sync --all-extras

you can install the amqp and mqtt libraries and thus run more tests. For the tests against an actual connection, see the next subsection.

Running tests against a running cattle_grid instance

Create an account on cattle_grid with

python -mcattle_grid account new almabtrieb password --admin

Then with cattle grid running one can run

CONNECTION_STRING=mqtt://almabtrieb:password@localhost:11883 \
    uv run pytest almabtrieb/test_real.py
CONNECTION_STRING=ws://almabtrieb:password@localhost:15675/ws \
    uv run pytest almabtrieb/test_real.py
CONNECTION_STRING="amqp://almabtrieb:password@localhost:5672/" \
    uv run pytest almabtrieb/test_real.py

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

almabtrieb-0.2.4.tar.gz (107.9 kB view details)

Uploaded Source

Built Distribution

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

almabtrieb-0.2.4-py3-none-any.whl (15.2 kB view details)

Uploaded Python 3

File details

Details for the file almabtrieb-0.2.4.tar.gz.

File metadata

  • Download URL: almabtrieb-0.2.4.tar.gz
  • Upload date:
  • Size: 107.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.14

File hashes

Hashes for almabtrieb-0.2.4.tar.gz
Algorithm Hash digest
SHA256 93e632ed27302114c7c72b6d155edce5687407e7ebc7c1e7b02fcff9f81ae04b
MD5 53e6f507e17d39d774b590aa4f5dff9e
BLAKE2b-256 38b5c0725d1489203cdc5e9cefe01355a3a024aea2eb5d0fa9916cae05935a51

See more details on using hashes here.

File details

Details for the file almabtrieb-0.2.4-py3-none-any.whl.

File metadata

  • Download URL: almabtrieb-0.2.4-py3-none-any.whl
  • Upload date:
  • Size: 15.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.14

File hashes

Hashes for almabtrieb-0.2.4-py3-none-any.whl
Algorithm Hash digest
SHA256 a8acad91f66790ba8a686531000e7c2275dcce0ad8e2fe2a746acc1a3c11d1af
MD5 8f29f8a48a8c8a8b8b4ea19bdb1cda1f
BLAKE2b-256 bbcac4c96d47808ec5a757b3f8bc6a1640e505d0db1388edd7bb11d75e752320

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