Skip to main content

abstraction-watch, in Python

Be told what is true now, and be told when nothing has changed for a while. A Notice carries the present; quiet says nothing visible has moved for at least the budget, and silence says for how long. One module, standard library only, importing nothing of ours.

Quiet is the half that is normally missing. A progress bar that stops moving and a transfer nobody is performing look identical to a listener that is only told about changes.

This page is the Python package. The contract, the Go and C++ implementations, what is measured and what is UNPROVEN are on the repository.

Install

Not on PyPI, and the name on PyPI is not ours.

git clone https://github.com/openabstractions/abstraction-watch
pip install ./abstraction-watch/python

Python 3.9 or later. abstraction_watch.py is one file with no imports of ours, so copying it into a _vendor/ directory of your own is an equally complete installation.

An example that runs

A source that says when it moved, and a listener that hears both the change and the quiet after it:

import abstraction_watch as watch

progress = watch.push({"done": 0}, stamp="0", budget=0.5)
progress.post({"done": 1 << 20}, stamp="1")

notice = progress.next()
print("now:", notice.now)

notice = progress.next()
print("quiet:", notice.quiet, "after", round(notice.silence, 1), "s of nothing")
progress.close()

budget=0.5 is the quiet budget and the only timer here: the listener's own wait decides when silence counts, so a change the source already made is always delivered ahead of a quiet that would postdate it.

What an application calls

call what it does
push(first, stamp, budget) a subscription over a source that reports its own changes through post
poll(read, every, budget) a subscription over a source that has to be asked. read returns (value, stamp); every is the interval between asks while a listener waits
Subscription.next(timeout=None) the next Notice: a change, or quiet once the budget passed with none
Subscription.current() what is true now, without waiting
Subscription.post(value, stamp) tell a push subscription the source moved
Subscription.close() end it. A waiting next raises Closed
settle(events, period, settled) call settled once a queue of platform notifications has been still for period, because one edit produces several of them

A subscription is iterable: for notice in subscription: ..., ending on close(). stamp is what decides whether a value is a change; two reads with the same stamp are one.

abstraction_job.watch(store, kind, budget) is this primitive with a job store as the source, which is what a download progress view binds to.

What may break

  • No conformance verdict, in any language. No scenario in the suite cites this layer yet — what is proven and what is not. Anything that depends on this layer inherits that.
  • Not on any package index, and no release carries an API stability promise. Pin a commit you have read.
  • poll asks; it does not subscribe to the platform. There is no inotify, no ReadDirectoryChangesW and no FSEvents under it. settle is the seam where a caller supplies those.
  • Every published transcript was produced on Windows or Linux. macOS is UNPROVEN throughout.

Apache-2.0. See LICENSE.

Metadata

Release files for abstraction-watch 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 abstraction-watch 0.1.0
File Size Uploaded Provenance Actions
abstraction_watch-0.1.0.tar.gz 8.2 kB With provenance Details for abstraction_watch-0.1.0.tar.gz

Built distribution (wheel)

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

Total release size: 17.1 kB

Release files / abstraction_watch-0.1.0.tar.gz

Download URL abstraction_watch-0.1.0.tar.gz
Size 8.2 kB
Tags Source
SHA-256 checksum
How to use checksums
3afed7e325d4aaa165891dcc9db364879cc72fbabb16a109279f7e2196ad803a
BLAKE2b-256 checksum
How to use checksums
bbd03f5045b50286af302b4123337f62ee1d8667a37b4c0df5b80dd5ba91f8d3
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 Sep 10, 2026.

Transparency log

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

Download URL abstraction_watch-0.1.0-py3-none-any.whl
Size 8.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
253eed30bd117b8a836fba2f1a5fc18676695eb35f7425456833bf10b524e159
BLAKE2b-256 checksum
How to use checksums
8205055a32b20bc478fcf89354afb7e85a54093753700013b4344b5b55fd4a97
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 Sep 10, 2026.

Transparency log

Security for abstraction-watch 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 abstraction_watch-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 Sep 10, 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.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files Full 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