Skip to main content

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 single source of truth is the canonical bhs-calendars/ directory at the repository root (also the npm package source). The JSON under bhs_calendars/data/ is a verbatim, build-time copy of it and is gitignored, not committed — the build, test, and release flows (and CI) regenerate it so it can never drift from the source.

When working in this repo, run make sync-py-calendars (or make sync-calendars for both ports) from the repo root once after checkout, and again after the source data changes, before building or testing this package.

Metadata

Release files for bhs-calendars 2.15.4

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

Source distribution (sdist)

Source distribution for bhs-calendars 2.15.4
File Size Uploaded Provenance Actions
bhs_calendars-2.15.4.tar.gz 12.8 kB With provenance Details for bhs_calendars-2.15.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for bhs-calendars 2.15.4
File Interpreter ABI Platform Actions
bhs_calendars-2.15.4-py3-none-any.whl Python 3 none any Details for bhs_calendars-2.15.4-py3-none-any.whl

Total release size: 39.7 kB

Release files / bhs_calendars-2.15.4.tar.gz

Download URL bhs_calendars-2.15.4.tar.gz
Size 12.8 kB
Tags Source
SHA-256 checksum
How to use checksums
4a939ab98f9e854ec6e827a6e984f6fbbd71ef7a89c4cd9d868b91c5dc4916c3
BLAKE2b-256 checksum
How to use checksums
765d8aae475972a1b9fa5ba72a08dbd61ac23efd8b4cb9d488c510e3f1b96712
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 4, 2026.

Transparency log

Release files / bhs_calendars-2.15.4-py3-none-any.whl

Download URL bhs_calendars-2.15.4-py3-none-any.whl
Size 26.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
db58e8f565b499982af2b51713d8b326d1c5589bc70d4a4d1cddd2a9aaf986c2
BLAKE2b-256 checksum
How to use checksums
9a744796d16a8498662ef1e7860daee102c5475de00fc9c0a6710f9436abe6a6
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 4, 2026.

Transparency log

Security for bhs-calendars 2.15.4

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 bhs_calendars-2.15.4.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 4, 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