Skip to main content

Bundled BHS-area school bell-schedule calendar data for the bells library

Reason this release was yanked:

Missing validation allowed bad data through.

Project description

bhs-calendars (Python)

Bundled bell-schedule calendar data for Berkeley High School and nearby middle schools, as a Python distribution. This is the Python counterpart of the npm @peterseibel/bhs-calendars package and ships the same per-year JSON.

It is data, not logic — pair it with the bells library to build schedules without supplying your own {year}.json files.

pip install bhs-calendars

Usage

from bhs_calendars import by_id, load_all
from bells import BellSchedule

# Grouped by school, each school's years sorted chronologically:
years = by_id()["bhs"]
schedule = BellSchedule(years, {})

# Or the flat list of every bundled school-year:
all_years = load_all()   # list[dict]

load_all() mirrors the npm package's default export (a flat list of yearly calendar objects). by_id() groups those by their id field — "bhs", "king-6", "king-7", "king-8", "longfellow-6", "longfellow-78", "willard-6", "willard-78" — with each group's years sorted by firstDay.

Unlike the library's Calendars loader (which reads {year}.json from a directory or URL), this data is bundled on disk with the package: no filesystem layout or network access required. The trade-off is that it only covers the BHS-area schools.

Data source

The JSON under bhs_calendars/data/ is copied verbatim from the canonical bhs-calendars/ directory at the repository root (the npm package source). Run make sync-calendars from the repo root to refresh it after the source data changes.

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

bhs_calendars-2.9.0.tar.gz (11.6 kB view details)

Uploaded Source

Built Distribution

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

bhs_calendars-2.9.0-py3-none-any.whl (25.5 kB view details)

Uploaded Python 3

File details

Details for the file bhs_calendars-2.9.0.tar.gz.

File metadata

  • Download URL: bhs_calendars-2.9.0.tar.gz
  • Upload date:
  • Size: 11.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for bhs_calendars-2.9.0.tar.gz
Algorithm Hash digest
SHA256 1933d986c63893b6e614a1e8508b3cd476877f71353fa112e2d893229519a33f
MD5 1c2e010e6f7ea23124fc7d6deadc7540
BLAKE2b-256 125f33da4d0940bc15a47fad697e8b3e2d72efe2dd83505cc20be6fc6f489a5a

See more details on using hashes here.

Provenance

The following attestation bundles were made for bhs_calendars-2.9.0.tar.gz:

Publisher: publish-calendars.yml on gigamonkey/bells

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file bhs_calendars-2.9.0-py3-none-any.whl.

File metadata

  • Download URL: bhs_calendars-2.9.0-py3-none-any.whl
  • Upload date:
  • Size: 25.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for bhs_calendars-2.9.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0597c26b11cab4caa3780870a7bd258cd2fd09eef4d133747984bb599b451d52
MD5 b336464054efd25c0f65a2849eee5d14
BLAKE2b-256 6ff4c3cec52a6c54010537def3854798a89b6ff3fa8b39d79732745d554f01d5

See more details on using hashes here.

Provenance

The following attestation bundles were made for bhs_calendars-2.9.0-py3-none-any.whl:

Publisher: publish-calendars.yml on gigamonkey/bells

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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