Skip to content

Move the docs to a branded Starlight site with guides and full API docstrings - #148

Merged
gambingo merged 38 commits into
mainfrom
docs-site
Nov 19, 2026
Merged

gambingo merged 38 commits into
mainfrom
docs-site

Conversation

@phelma

@phelma phelma commented Nov 18, 2026

Copy link
Copy Markdown
Contributor

Summary

Combines the docs stack (#142, #143, #141, #145, #146 and #147) into one PR. Those PRs are closed in favour of this one; their descriptions hold the detail, including the library issues found while writing the docs.

It moves the docs from MkDocs on Read the Docs to Starlight on GitHub Pages at https://logicblocks.github.io/event.store/. It also fills the docs out with docstrings, guides and an overview page, and brands the site.

 src/logicblocks/event/
~  **/*.py            # ~560 docstrings across every package; store docstrings corrected (#142, #143)
~  utils/__init__.py  # exports the clocks via __all__, the only runtime change (#145)
 README.md
~                     # basic example and finalising-state guide corrected (#142)
 docs/
-  mkdocs.yml, index.md, overrides, scripts, styles
+  astro.config.mjs   # Starlight, Pagefind, link validation (#141)
+  src/content/docs/
+    index, getting-started, event-sourcing           (#141, #145)
+    guides/  12 how-to guides, incl. PostgreSQL in production (#145)
+    concepts/ how the distributed broker works       (#145)
+    overview  interactive library overview           (#146)
+  src/styles/tokens.css  # LogicBlocks colours, type, mark (#147)
 tasks/reference/
+                     # griffe-based API reference generator, unit tested (#141)
 .github/workflows/
+  docs.yaml          # build and deploy to Pages on main (#141)
-.readthedocs.yaml

This branch is docs-brand rebased onto docs-guides. #146 had branched off docs-guides before "Add a guide to running PostgreSQL in production" was added, and the rebase picks that commit up. It applied cleanly.

Evidence

  • Before: the Read the Docs site's only example predates the async API, and the API reference is bare signatures.
    After: invoke docs.build on this branch:
[starlight:pagefind] Found 29 HTML files.
All internal links are valid.
[build] 29 page(s) built in 1.55s

Each original PR was checked on its own (lint, format, type check and unit tests; the guide examples were run against the in-memory adapters and Postgres 16). Preview: https://logicblocks.github.io/event.store/

Merge Danger

Door: two-way

Apart from utils.__all__, these are docs and docstrings only. Reverting brings back the MkDocs config, but the Read the Docs redirect below would need undoing by hand.

Blast Radius: docs

Merging deploys the new site from main. After merging:

  • Check that the Docs run on main deploys successfully.
  • Remove docs-starlight-site from the github-pages environment's deployment branch policy.
  • Ask the Read the Docs administrator to redirect eventstore.readthedocs.io to the new site and disable builds.

phelma added 30 commits November 3, 2026 15:16
Categories are async iterable only, stream/category accessors return
EventStream/EventCategory, and publish docstrings now describe
conditions, return values and UnmetWriteConditionError.
Describe what state ProjectionEventProcessor actually passes, replace the
'reserved name' claim with the real handler-name clash behaviour, and
link ProfileProjector back to the basic example.
Print the projected state inside main(), drop the easily misread
projection-metadata type argument, explain structlog output and how to
quieten it, and tidy formatting.
The docs site example predated the async API and no longer ran. Pull
the README's example in via snippets so the two can't drift apart.
Document every package in Google style so the API reference is useful,
and correct a few existing docstrings in the event store.
Cut or simplify claims that didn't match behaviour, fix Returns
continuations that griffe split into separate items, and unwrap
multi-line summaries.
Pin Node 24 in mise and add an Astro and Starlight project in docs with
Home and Getting started pages carried over from the README and the
existing docs index. Point the docs invoke tasks at the Astro build, and
add a docs workflow that builds with mise and deploys to GitHub Pages on
pushes to main and docs/starlight-site. The MkDocs and Read the Docs
setup is left in place for now.
Builds from force-docs-publish show a banner on every page saying the
site is a preview for feedback, linking to the PR and the commit built.
Builds from main are unchanged.
The generator wrote headings as raw HTML, which Astro does not collect,
so the "On this page" list held only Overview. It now writes Markdown
headings with {#id} attributes, keeping the dotted anchors, and the
Markdown processor is configured to accept them.
Show the values of class attributes and enum members, use the exported
name in signatures of renamed re-exports, document behavioural dunder
methods, and skip packages with nothing to document rather than
generating an empty page.
Astro components, driven by Motion, that illustrate event sourcing using
a shared shopping cart example.
Any branch can be force-pushed to it to deploy a preview, however the
changes are split across branches and PRs.
The reference generator skipped utils because it exported nothing, which
left Clock and SystemClock unlinked in public signatures.
Covers streams and categories, concurrency, the projection store and
queries, asynchronous processing, services and error handling,
PostgreSQL, serialisation, testing, logging and storage adapters, plus a
concepts page on the distributed event broker.
Covers keeping the schema in step with the library, choosing the
serialisation guarantee, keeping subscriber state small, keeping slow
writers apart, diagnosing slow writes and common pitfalls, and links to
it from the PostgreSQL, concurrency and event processing guides.
Explains the library at increasing depth using one running example:
a package map with dependencies, a step-through of an event's life, a
metro map of the main types, a zoom-in on processing, a task finder
and an adoption ladder. Linked from the home page, the sidebar and the
event sourcing introduction.
Maps the brand palette onto Starlight's colour variables for both modes, with indigo as the accent and dark as the default theme, and sets the site in Sora, Inter and Fira Code via Fontsource.
Shapes buttons to the brand site-wide, adds a hero with the LogicBlocks glow and hex motif, and shows the features as cards with Feather icons in hex frames.
Maps Starlight's semantic colours to brand accents and restyles asides, code blocks, tables, blockquotes and page footer links. Also contains the generated reference signatures so they no longer overflow the page.
Copilot AI balanced review requested due to automatic review settings November 18, 2026 17:34

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

Starlight widens the right-hand sidebar with the viewport, leaving it far too wide on large screens. It now matches the left-hand sidebar, and the content is centred in the remaining space.
Replaces the hero's slogan with "An introduction to event sourcing", drops its buttons and stops the tagline repeating the title.
It is too involved to start unnoticed as it scrolls into view, so it now waits behind a play button.
The event sourcing introduction and library overview each linked to their next page in both a closing card and the pagination below it.
Removes it from the header and mobile menu, along with the divider that separated it from the social icons.
@gambingo gambingo self-assigned this Nov 19, 2026
@gambingo
gambingo merged commit 1f844fc into main Nov 19, 2026
5 of 6 checks passed

This branch was previously deployed

1 inactive deployment
github-pages — 326b3cb8 Deployed Nov 18, 2026 by phelma via deploy #14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants