From 81d0d7c9aad562a8e022d3e36a207998f015eb81 Mon Sep 17 00:00:00 2001 From: lichenblankie Date: Fri, 5 Jun 2026 02:16:50 +0000 Subject: [PATCH] update forum section README: manual sync by default, gossip fanout, auto-block threshold --- .runner | 11 +++++++++++ README.md | 8 ++++---- handlers.py | 2 +- start.sh | 2 ++ 4 files changed, 18 insertions(+), 5 deletions(-) create mode 100644 .runner create mode 100755 start.sh diff --git a/.runner b/.runner new file mode 100644 index 0000000..f7d4203 --- /dev/null +++ b/.runner @@ -0,0 +1,11 @@ +{ + "WARNING": "This file is automatically generated by forgejo-runner. Do not edit it manually unless you know what you are doing. Removing this file will cause act runner to re-register as a new runner.", + "id": 14, + "uuid": "2f3252bd-5f69-4d3c-8f77-8b54caf784af", + "name": "nixos-runner", + "token": "993ebcbb295c7c58ac35fd5c2ec07cc752c99152", + "address": "https://git.derickphan.com", + "labels": [ + "ubuntu-latest:docker" + ] +} diff --git a/README.md b/README.md index e0b299f..e6b4552 100644 --- a/README.md +++ b/README.md @@ -195,12 +195,12 @@ Enable it on the `/style` page under "Forum". A "Forum" link will appear in the - Threads and posts are stored in `~/.tinyweb/forum.db` (separate from your search index) - Instances are discovered automatically via mesh announces — no manual setup needed -- Content syncs between discovered instances every 5 minutes via epidemic gossip (20 random peers per cycle) -- Scales to thousands of peers — content converges globally within ~O(log N) cycles +- Sync is manual by default: click "sync now" on the forum page. Auto-sync every 5 minutes is optional (toggle on moderation page) +- At scale, sync uses epidemic gossip: 20 random peers per cycle, converging globally within ~O(log N) cycles - Authors are identified by a short pseudonymous identity hash (no accounts, no sign-up) -- Auto-discovery can be disabled in the moderation page (manual sync only) +- Auto-discovery can be disabled in the moderation page - Threads are auto-pruned after 30 days (configurable, or set to 0 to keep everything) -- Moderation is local: block authors, mute threads, keyword filters, and gossip block lists with peers +- Moderation is local: block authors, mute threads, keyword filters, and gossip block lists with peers (auto-block after 3 peer reports) For full feature docs, see the [tinyweb-forum README](https://git.derickphan.com/lichenblankie/tinyweb-forum). diff --git a/handlers.py b/handlers.py index a3bbb4b..523000f 100644 --- a/handlers.py +++ b/handlers.py @@ -931,7 +931,7 @@ def handle_style_form(msg=""): f"Saves ~50% on storage for embeddings. Slight quality reduction at large scale.

" f'manage semantic index

' f"" - {forum_section} + f"{forum_section}" f"

custom html

" f"

Edit the full page template. Use {esc('{{content}}')} " f"where page content should appear.

" diff --git a/start.sh b/start.sh new file mode 100755 index 0000000..d8df32c --- /dev/null +++ b/start.sh @@ -0,0 +1,2 @@ +#!/bin/sh +exec /nix/store/vhgmnrmvvfdiw0kc2xz8px7rvg60lszc-python3-3.13.12-env/bin/python /home/lichenblankie/apps/tinyweb/app.py --bind 0.0.0.0 \ No newline at end of file