#ppoppo #workspace #port #timer #clock #jiff #ccc

ppoppo-clock

Universal Clock + Timer port for ppoppo workspace — chat-as-infrastructure primitive

12 releases (7 breaking)

Uses new Rust 2024

new 0.25.0 Aug 29, 2026
0.23.0 Aug 28, 2026
0.20.0 Jul 28, 2026

#958 in Web programming

Download history 58/week @ 2026-07-11 26/week @ 2026-07-18 10/week @ 2026-07-25 11/week @ 2026-08-01 37/week @ 2026-08-08 9/week @ 2026-08-15 18/week @ 2026-08-22

75 downloads per month
Used in 7 crates (4 directly)

MIT/Apache

26KB
455 lines

NOT a stable public API. Engine-tier time port — 3rd parties reach it via the SDK-family re-exports (e.g. ppoppo_pas_external::clock::*) and never name this crate directly. 1st-party clients outside this workspace do name it: the standalone CCC repo (RFC_202607180403) depends on it from crates.io, and must pin the same family version ppoppo-chat-client requires or cargo resolves two copies and the shared Clock trait stops typechecking across them. Do not build a 3rd-party integration on this crate's API expecting stability.

Universal Clock + Timer port for the ppoppo workspace.

Single deep-module port hiding the time-source substrate from every consumer. Three impl arms gated by feature: native (Tokio), wasm (js_sys::Date + Intl tz-name probe + Window.setTimeout), mock (FrozenClock + MockClock + AdvanceableTimer). Zone math is arm-independent: jiff's bundled tzdb makes now_in/today_in provided methods — each arm implements only now().

SSOT relationship

Standards: STS_TIME_MECHANICS.md §"Universal client + server time port" (jiff surface per RFC_202607130309_jiff-migration). Engine precedent: ppoppo-token (1st-party-consumed primitive, surface via SDK re-export). External Developer Apps consume via ppoppo_pas_external::clock::* — never path-dep this crate.

Temporal alignment

jiff is the Rust realization of the TC39 Temporal model (TimestampTemporal.Instant, ZonedTemporal.ZonedDateTime, civil::DateTemporal.PlainDate, tz::TimeZoneTemporal.TimeZone). The pre-jiff plan to swap the wasm arm onto js_sys::Temporal is obsolete — the model already lives in-process, identically on every arm.

Dependencies

~4–8MB
~131K SLoC