Skip to main content

hwp5

hwp5 is a small Python library that scans calendar export files (.ics) to find hard-work patterns over rolling 5-day windows.

It is useful when you want to answer:

  • "Did I do at least 20 focused work hours over any 5-day period?"
  • "Which calendar periods were my most intense hard-work blocks?"

Features

  • Reads standard ICS calendar exports.
  • Filters events by keyword in SUMMARY (default: hard work, deep work, focus).
  • Computes rolling N-day windows (default: 5 days).
  • Returns only windows that pass a minimum total-hour threshold.
  • Includes a CLI command (hwp5) and importable Python API.

Installation

pip install hwp5

CLI usage

hwp5 calendar.ics
hwp5 calendar.ics --window-days 5 --min-hours 25
hwp5 calendar.ics --keyword "hard work" --keyword "coding" --json

Example output:

Hard-work windows found:
- 2026-05-01 to 2026-05-05: 21.5h across 7 events
- 2026-05-02 to 2026-05-06: 24.0h across 8 events

Python usage

from hwp5 import load_ics_events, find_hard_work_windows

events = load_ics_events("calendar.ics")
windows = find_hard_work_windows(events, window_days=5, min_hours=20)
for w in windows:
    print(w.start_date, w.end_date, w.total_hours)

Publish to PyPI

  1. Update version in pyproject.toml.
  2. Build:
    python -m pip install --upgrade build twine
    python -m build
    
  3. Check package:
    python -m twine check dist/*
    
  4. Upload:
    python -m twine upload dist/*
    

Development

python -m pip install -e ".[dev]"
pytest

Metadata

Release files for hwp5 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 hwp5 0.1.0
File Size Uploaded Provenance Actions
hwp5-0.1.0.tar.gz 5.8 kB Without provenance Details for hwp5-0.1.0.tar.gz

Built distribution (wheel)

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

Total release size: 11.9 kB

Release files / hwp5-0.1.0.tar.gz

Download URL hwp5-0.1.0.tar.gz
Size 5.8 kB
Tags Source
SHA-256 checksum
How to use checksums
4182d3ac6f651dcb861d9ec32fe5eb1de0d214c16648e73aaad0d1f9edcff14c
BLAKE2b-256 checksum
How to use checksums
e4ee1f37a3725a58c16e70960e0c15ebafacb48b2fc3659e2e045255b8adf47b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.10

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

Download URL hwp5-0.1.0-py3-none-any.whl
Size 6.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
aa15ea1c0a2da9afdc6e87d1b81e220da559523677422bdc69ef2871576b5a8b
BLAKE2b-256 checksum
How to use checksums
744762889d3f4a99b7566844fa1ca988143050096c535d3430d663d13336e57d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.10

Security for hwp5 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.

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.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

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