Things that will bite you

Collected from actually building this node.

Adding or renaming a page needs a restart. Handlers are registered when the node scans pages at startup. Editing an existing page does not: the file is read on each request. The execute bit is also read per request, so flipping an existing page from static to executable needs no restart either.

A restart drops every identification. Anyone who had identified must do it again. Plan maintenance accordingly.

A crashing page returns nothing. There is no traceback in the response and stderr is discarded. If a page returns an empty document, run it by hand with a stripped environment and read the traceback there.

Clients are not identical. This node is reached both from the NomadNet terminal client and from MeshChatX in a browser, and they do not render or submit identically. MeshChatX sanitises the HTML it generates, and that sanitiser deletes the name attribute of any input whose name collides with a property of document or of a form. Fields called title, body, name and location therefore arrived with no name at all, every submit form on this node silently discarded its input, and nothing in the logs said so. Prefix field names -- topic_title, item_location -- and the problem disappears.

Emoji are East Asian Wide and occupy two cells. Any column you pad by counting characters will be crooked the moment an icon appears in it. Some glyphs are worse: box-drawing characters and symbols like the black diamond are East Asian Ambiguous and may be one cell or two depending on the terminal. Do not put those in a padded column at all.

Write library code in a .py beside the pages, import it, and keep it non-executable. Everything under pages/ is servable; a .py with the execute bit set is a page that runs with no timeout.

Web edition of Taskerville, a NomadNet node on the Reticulum mesh, built to keep working over radio when the internet does not. Node address 27cfd74b0a14e7d4f327a9de26d0e8cc.

----------------------------------------------------------------------------------------
----------------------------------------------------------------------------------------
A BMRL Project
27cfd74b0a14e7d4f327a9de26d0e8cc
[0] bmrl* "~/changelog"