timescale.info
Sign inSign up

How OpenChronology was built

Every merged pull request of openchronology/timeline-app, its first week of commits and its releases; and before them the 2020 PureScript editor, from snapshots of its deleted repositories in the Wayback Machine. Written to this server through the HTTP API.

327 moments · 2020-03-09T00:15:08Z CE – 2026-11-02T20:11:21Z CE · by @athan · @athan

#425 · A timeline's settings page opens when it no longer keeps saved history

  • timeline-app
  • pull request

A timeline's **Sharing & settings** page fails with "The page is temporarily unavailable" for any timeline that has stopped keeping saved history. This was found while staging the operations pitch video, and it's live on timescale.info. ## Cause `platform/components/timeline-settings.jsx` attached its backdrop handling to the saved-history confirmation dialog once, on mount, with `useEffect(() => dismissOnBackdrop(historyDialog.current), [])`. That dialog renders only while history is kept, so for a timeline that stopped keeping it the ref is `null`, `dismissOnBackdrop(null)` throws, and the page's client render fails. ## Fix The effect runs whenever `timeline.keep_history` changes and attaches only when the dialog exists. Turning history back on also gets backdrop dismissal again, which it didn't before. ## Test `test/labels-live-postgres.mjs`, which already opens the settings page in a browser, now: 1. stops keeping saved history through the dialog; 2. reloads the page, which is the crash; 3. turns history back on; 4. checks that the confirmation dialog closes on a backdrop click. The test fails without the fix (the page never renders after the reload) and passes with it.

Sources

Open #425 · A timeline's settings page opens when it no longer keeps saved history in the timeline