Skip to main content

Helpful tools to test Fediverse Applications

Project description

Fediverse Pasture

This python package contains tools to test Fediverse applications. This package uses bovine for a lot of the Fediverse related logic. It should also be noted that the aim here is to debug issues caused by federation, thus everything involves starting a webserver and running requests against it.

Usage

For usage information, see the documentation.

With docker container

One can start the one actor server via

docker run --rm --name pasture\
    --hostname pasture-one-actor --network fediverse-pasture\
    helgekr/pasture one_actor

and then use the send tool via

docker exec pasture ./send acct:user@domain

Afterwards you should stop the container with docker stop pasture.

Development

Install the necessary dependencies via

uv sync --all-extras

To lint and check code formatting run

uv run ruff check .
uv run ruff format .

To test the code run

uv run pytest

With docker

To start the local environment in docker run

docker run --detach --rm --name pasture-dev\
    --hostname pasture-one-actor\
    --network fediverse-pasture\
    -v .:/data --workdir /data\
    -e UV_PROJECT_ENVIRONMENT=/tmp/venv\
    ghcr.io/astral-sh/uv:python3.11-alpine\
    uv run python -mfediverse_pasture.one_actor --port 80

and then

docker exec -ti -e UV_PROJECT_ENVIRONMENT=/tmp/venv pasture-dev \
    uv run python -mfediverse_pasture.send acct:user@domain

to send a message.

Releasing

Releasing is done automatically on merge to the main branch. For this to happen, the following has to be true

  • There exists a milestone with the version number
  • All issues in the milestone are closed
  • There exists an entry in CHANGES.md
  • The package version has the same version number

See https://codeberg.org/helge/release_helper

Funding

This code was created as part of Fediverse Test Framework.

A project funded through the NGI0 Core Fund, a fund established by NLnet with financial support from the European Commission's Next Generation Internet programme, under the aegis of DG Communications Networks, Content and Technology under grant agreement No 101092990.

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

fediverse_pasture-0.2.25.tar.gz (489.7 kB view details)

Uploaded Source

Built Distribution

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

fediverse_pasture-0.2.25-py3-none-any.whl (59.5 kB view details)

Uploaded Python 3

File details

Details for the file fediverse_pasture-0.2.25.tar.gz.

File metadata

  • Download URL: fediverse_pasture-0.2.25.tar.gz
  • Upload date:
  • Size: 489.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.5

File hashes

Hashes for fediverse_pasture-0.2.25.tar.gz
Algorithm Hash digest
SHA256 b1061ae1da179697d8d4d3fc4e266b0379a5dd16299d76b701c73b73eb1e12a1
MD5 9858f821fe2f4e34b4a33faac035d03b
BLAKE2b-256 87476fee124b10bbf46d94b398eaba155ba6ab7e6d9932b55aac5f05c89f486f

See more details on using hashes here.

File details

Details for the file fediverse_pasture-0.2.25-py3-none-any.whl.

File metadata

File hashes

Hashes for fediverse_pasture-0.2.25-py3-none-any.whl
Algorithm Hash digest
SHA256 9fbf4402416b8bb8c32d091386ea108afe9ba94f892188b0d757c6ce32fa592c
MD5 493bde87e6ebda029b2487724514fc88
BLAKE2b-256 b08027b9965b57f57c353feec94bca91b48da1800318955d87b28e602cc5ada9

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