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.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 bhs-calendars 2.13.0
File Size Uploaded Provenance Actions
bhs_calendars-2.13.0.tar.gz 12.5 kB With provenance Details for bhs_calendars-2.13.0.tar.gz

Built distribution (wheel)

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

Total release size: 38.8 kB

Release files / bhs_calendars-2.13.0.tar.gz

Download URL bhs_calendars-2.13.0.tar.gz
Size 12.5 kB
Tags Source
SHA-256 checksum
How to use checksums
7e2612511508e1f3d1d93deedf3c88c1e307ea656236b757f25d6567cdde4884
BLAKE2b-256 checksum
How to use checksums
fb8f5374e45ae8eb35cd09fa6bc78bdc13fff6d7c960762fa75145643a9961cb
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 Aug 18, 2026.

Transparency log

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

Download URL bhs_calendars-2.13.0-py3-none-any.whl
Size 26.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
28114111798a41ffb5598ff95cc01b7b106e3cfa002e18dafbe4aadf628bd531
BLAKE2b-256 checksum
How to use checksums
15839f42321832bff9bb985ee201371b2e171472493933a8b9e1f30a0e013907
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 Aug 18, 2026.

Transparency log

Security for bhs-calendars 2.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.

Full provenance

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

Select from 2 files

Attestation for bhs_calendars-2.13.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 Aug 18, 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