Skip to main content

squoredata

Self-contained Pydantic v2 data structures used by Squore scoreboard tablets.

The package was extracted from tcboard. It contains only the data models, not the surrounding server logic. TypeScript bindings are generated from the models so that a JavaScript or TypeScript project can consume the same shape.

Models

  • SquoreMatch — a match as used by Squore, without any live information.
  • SquoreMatchLiveData — a SquoreMatch together with the live data a tablet reports. It adds the court and timestamp fields.

Supporting models: Players, Colors, Countries, Clubs, Event, Format, Wifi, Metadata, SquoreDeviceInfo, TimerInfo, Timing, When, Point, Game, and the LiveStatus enum.

Install

pip install squoredata

TypeScript bindings

scripts/generate_ts.py renders the JSON Schema of each model and converts it to TypeScript with json-schema-to-typescript. The output lives in typescript/ and is committed:

  • SquoreMatch.d.ts, SquoreMatchLiveData.d.ts — the interfaces
  • SquoreMatch.schema.json, SquoreMatchLiveData.schema.json — the schemata
  • index.d.ts — re-exports

The Hatch build hook (hatch_build.py) runs the generator before a wheel is built, so a release can never carry stale bindings.

Install the generated bindings into another project from the typescript/ directory, or from a published squoredata-types package:

npm install /path/to/squoredata/typescript

Golden tests

The files in golden/ are the shared contract between the two sides:

  • tests/test_golden.py serialises and re-validates the models against the golden JSON.
  • typescript/tests/golden.ts assigns the same JSON to the generated interfaces, so tsc --noEmit fails when the two sides diverge.

Regenerate the golden files with python scripts/make_golden.py after a model change.

Development

pip install -e .[dev]
ruff check .
pytest
mypy --strict .

npm install
node_modules/.bin/tsc --noEmit -p tsconfig.json

Metadata

Release files for squoredata 0.1.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 squoredata 0.1.0
File Size Uploaded Provenance Actions
squoredata-0.1.0.tar.gz 16.7 kB With provenance Details for squoredata-0.1.0.tar.gz

Built distribution (wheel)

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

Total release size: 27.1 kB

Release files / squoredata-0.1.0.tar.gz

Download URL squoredata-0.1.0.tar.gz
Size 16.7 kB
Tags Source
SHA-256 checksum
How to use checksums
b1ffc5f2b7ba6cdd1195e9ebc177163eba0e411cca7ee2ec5f38dc1fa8d2b3e8
BLAKE2b-256 checksum
How to use checksums
008c3a06ee9126f7237bd1b538ebda8cdd25cecd76c21bc90d4c11d2ff8c6c0d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Release files / squoredata-0.1.0-py3-none-any.whl

Download URL squoredata-0.1.0-py3-none-any.whl
Size 10.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
997475d8d201ad3022631a860ac041f48c6774a6ef89ab1ad371531cda6e0802
BLAKE2b-256 checksum
How to use checksums
715fffe281de3e8cec69b6d119f1794e52c8ae0c3dafb02b3212efed901e075d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

Security for squoredata 0.1.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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for squoredata-0.1.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 14, 2026.

Transparency log

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