Skip to main content

Python library for the OrgaTalk LAN Party Database

This library provides

  • party and party series models,
  • functionality to deserialize parties and party series from TOML, and
  • functionality to serialize parties and party series to TOML

to work with data for and from the public LAN party database by OrgaTalk.

Data and code repositories for the project are available at: https://github.com/lanpartydb

Status

Test

Installation

With pip:

$ pip install lanpartydb

Or with uv:

$ uv init
$ uv add lanpartydb

Usage

To serialize a party with only the required attributes to TOML:

from datetime import date

from lanpartydb.models import Party
from lanpartydb.serialization import serialize_party_to_toml

party = Party(
    slug='megalan-2023',
    title='MegaLAN 2023',
    start_on=date(2023, 11, 17),
    end_on=date(2023, 11, 19),
)

toml = serialize_party_to_toml(party)

print(toml)

And to serialize a party with all available attributes to a TOML file:

from datetime import date
from decimal import Decimal
from pathlib import Path

from lanpartydb.models import Location, Party, PartyLinks, Resource
from lanpartydb.serialization import serialize_party_to_toml

party = Party(
    slug='superlan-2024',
    title='SuperLAN 2024',
    series_slug='superlan',
    organizer_entity='SuperLAN Association',
    start_on=date(2024, 5, 24),
    end_on=date(2024, 5, 26),
    online_only=False,
    seats=420,
    attendees=397,
    location=Location(
        name='City Hall',
        country_code='us',
        city='Los Angeles',
        postal_code='90099',
        street='123 North Hill Street',
        latitude=Decimal('34.06101057935884'),
        longitude=Decimal('-118.23974355902666'),
    ),
    links=PartyLinks(
        website=Resource(
            url='https://www.superlan.example/',
            offline=False,
        ),
    ),
)

toml = serialize_party_to_toml(party)

path = Path('./superlan-2024.toml')
path.write_text(toml)

Take a look at the code (in src/) and the tests (in tests/) to learn more about the library's interface.

License

MIT

Author

Jochen Kupperschmidt

Metadata

Release files for lanpartydb 0.13.0

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

Source distribution (sdist)

Source distribution for lanpartydb 0.13.0
File Size Uploaded Provenance
lanpartydb-0.13.0.tar.gz 4.0 kB Without provenance Details

Built distribution (wheel)

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

Total release size: 9.8 kB

Release files / lanpartydb-0.13.0.tar.gz

Download URL lanpartydb-0.13.0.tar.gz
Size 4.0 kB
Tags Source
SHA-256 checksum
How to use checksums
824a01787d93dded4435fe019af90f3a8073ad3924a4e35a543655b587e4d409
BLAKE2b-256 checksum
How to use checksums
6d0ca81b566631f85f8769e7c2327b49b16f53195cc26601fdee41f229f94b14
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.3 {"installer":{"name":"uv","version":"0.11.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / lanpartydb-0.13.0-py3-none-any.whl

Download URL lanpartydb-0.13.0-py3-none-any.whl
Size 5.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0de6194b17172be144da16069c25d51626d32c1297c40155655e88efce438f84
BLAKE2b-256 checksum
How to use checksums
d5514d3b10ef0abd4faab579ac9ecc92bd00abaecd89d493af885ad7920f3aef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.3 {"installer":{"name":"uv","version":"0.11.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Security for lanpartydb 0.13.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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