From 23e950c372df8fb17fea8af7805418ed754e8f47 Mon Sep 17 00:00:00 2001 From: mnovak Date: Sun, 1 Nov 2026 21:31:28 +0100 Subject: [PATCH 1/2] [docs] ArtStyle: Record Mark's approval of STYLE.md, S1-S5 kept as drafted --- .agents/FEATURES.md | 2 +- .agents/GAP_ANALYSIS.md | 2 +- .agents/features/art-pipeline.md | 2 +- .agents/reviews/feature-art-board.md | 2 +- HANDOVER.md | 5 ++--- art/STYLE.md | 12 ++++++------ docs/ART.md | 4 ++-- 7 files changed, 14 insertions(+), 15 deletions(-) diff --git a/.agents/FEATURES.md b/.agents/FEATURES.md index 3dc8f08..dee683d 100644 --- a/.agents/FEATURES.md +++ b/.agents/FEATURES.md @@ -8,4 +8,4 @@ One row per feature, with its analysis document (CLAUDE.md §5.1). Gaps live in | Workspace, contracts, gates, PWA shell | 0 | Merged to `main` 2026-11-01 (`d11d242`); built, not deployed. Phase 0 gate still open | [phase0-workspace.md](features/phase0-workspace.md) | [feature-phase0-workspace.md](reviews/feature-phase0-workspace.md) | | Roadmap and gameplay docs, read against the code | 0 | Merged 2026-11-01; Q1–Q7 answered by the author | — | [docs-roadmap-gameplay.md](reviews/docs-roadmap-gameplay.md) | | The Letter slot: page at `#letter`, empty `docs/LETTER.md` | 0 | Merged to `main`; built, not deployed. Invisible until the author writes | [letter-slot.md](features/letter-slot.md) | [feature-letter-slot.md](reviews/feature-letter-slot.md) | -| The art pipeline and the art board: STYLE.md draft, Phase 1 manifest, stand-ins, `tools/art-prep`, the published board | 0 | Merged to `main`; board published (private). The app is unchanged. Gate waits on the first real picture | [art-pipeline.md](features/art-pipeline.md) | [feature-art-board.md](reviews/feature-art-board.md) | +| The art pipeline and the art board: STYLE.md (approved), Phase 1 manifest, stand-ins, `tools/art-prep`, the published board | 0 | Merged to `main`; board published (private). The app is unchanged. Gate waits on the first real picture | [art-pipeline.md](features/art-pipeline.md) | [feature-art-board.md](reviews/feature-art-board.md) | diff --git a/.agents/GAP_ANALYSIS.md b/.agents/GAP_ANALYSIS.md index a8446fe..6901583 100644 --- a/.agents/GAP_ANALYSIS.md +++ b/.agents/GAP_ANALYSIS.md @@ -40,7 +40,7 @@ board exist, and the first real picture is the author's to make. | G0.21 | No PNG icons | Open (predicted trap). iOS ignores SVG for `apple-touch-icon`. Comes through the art pipeline. | | G0.22 | No CI | Open. Every gate ran on this machine only. With G0.13. | | G0.23 | Source maps are built and would be published | Open. `sourcemap: true`; maps are not precached. Decide with G0.13 whether the repository is public. If not, use `'hidden'`. | -| G0.24 | No art pipeline: `docs/ART.md`, `art/STYLE.md` (drafted with the author), `art/manifest.json` for Phase 1 assets, SVG placeholders, `tools/art-prep` | **Pipeline built 2026-11-01** (`feature/art-board`): docs/ART.md, the Phase 1 manifest (25 pictures), 29 generated stand-ins, `tools/art-prep` (50 tests; 5 of 5 put-back bugs caught), the art board published. **Still open:** STYLE.md is Claude's draft waiting for the author (S1–S5), and the **Phase 0 gate**, one real picture through every step into `art/final/`. | +| G0.24 | No art pipeline: `docs/ART.md`, `art/STYLE.md` (drafted with the author), `art/manifest.json` for Phase 1 assets, SVG placeholders, `tools/art-prep` | **Pipeline built 2026-11-01** (`feature/art-board`): docs/ART.md, the Phase 1 manifest (25 pictures), 29 generated stand-ins, `tools/art-prep` (50 tests; 5 of 5 put-back bugs caught), the art board published. STYLE.md approved by the author 2026-11-01 (S1–S5 kept as drafted; `docs/style-approved`). **Still open:** the **Phase 0 gate**, one real picture through every step into `art/final/`. | | ~~G0.25~~ | ~~No slot for *A Letter from the Gardener*~~ | Closed 2026-11-01, merged to `main`. `docs/LETTER.md` holds slots as comments only; the page opens at `#letter` once it has words. 16 ui tests, and e2e on both the empty and a temporary written letter. Mutations caught: the link while empty, any link scheme, focus not moving, *heal* in the letter. | | G0.27 | The quiet door to real help has no numbers (§5.6 rule 5) | Open. The slot is in `docs/LETTER.md`. Support lines are real-world facts the author must verify, per country, so the door exists only once the letter does. | | ~~G0.26~~ | ~~Not decided: how the sunset invitation reaches the player on the web~~ | Closed 2026-11-01 by the author (Q6): in-app only on the web, no push server; local notifications through the Tauri shell in Phase 6. Recorded in ROADMAP Phase 0 and CLAUDE.md §8. | diff --git a/.agents/features/art-pipeline.md b/.agents/features/art-pipeline.md index 6d38470..b06fe07 100644 --- a/.agents/features/art-pipeline.md +++ b/.agents/features/art-pipeline.md @@ -77,7 +77,7 @@ typecheck and lint. Nothing imports it: not the app, not the packages. | Gap (G0.24) | Solution | State | |:--|:--|:--| | No `docs/ART.md` | Written: the six steps, the manifest's rules, the board, budgets, what's missing | Done | -| No `art/STYLE.md` "drafted with Mark" | A draft by Claude, with its open choices S1–S5 listed for Mark | **Draft.** Mark's approval is still needed | +| No `art/STYLE.md` "drafted with Mark" | A draft by Claude, with its open choices S1–S5 listed for Mark | Done: Mark kept the draft, 2026-11-01 | | No `art/manifest.json` | 11 cards, 25 Phase 1 pictures: rose sheet, stages, care, moments, care things, chair, four garden layers, icon | Done | | No SVG placeholders | 29 stand-ins, generated and committed | Done | | No art preparation page | The art board, published (A1) | Done | diff --git a/.agents/reviews/feature-art-board.md b/.agents/reviews/feature-art-board.md index fd14d23..c84ad00 100644 --- a/.agents/reviews/feature-art-board.md +++ b/.agents/reviews/feature-art-board.md @@ -49,7 +49,7 @@ runtime, so it showed its read-only state. Upload and Accept were **not** exerci | 4 | **Soul** | The rose's moods are where guilt can enter art: a thirsty or waiting rose drawn as hurt blames the player (§8). | **Addressed in the prompts**: *tired, not hurt*, *gently comic, never ill*, *quiet, waiting with patience, never sad, hurt or blaming*. Review point 7. The real pictures still need looking at, which is Mark's and Claude's job on the board. | | 5 | **Privacy** | The board stores pictures on claude.ai. | **Accepted**: only generated art and Mark's notes. The app never contacts the board, and art reaches the app only through git. Nothing about a player exists there. | | 6 | Process | The roadmap and CLAUDE.md planned `tools/art-prep` as a 127.0.0.1 page. The board replaces it at Mark's request. | **Recorded**: ROADMAP Phase 0 *Decided 2026-11-01*, CLAUDE.md §2, §3 and §9, docs/ART.md §3. | -| 7 | Correctness | STYLE.md is Claude's draft. The roadmap says *drafted with Mark*. Every prompt on the board inherits the draft. | **Open**: S1–S5 in STYLE.md §0 wait for Mark. The first card, `rose-sheet`, is the test. If it looks wrong, STYLE.md changes, `art:board` rebuilds and the board is republished. | +| 7 | Correctness | STYLE.md is Claude's draft. The roadmap says *drafted with Mark*. Every prompt on the board inherits the draft. | **Closed 2026-11-01**: Mark kept the draft; S1–S5 are decided (`docs/style-approved`). Still true: the first card, `rose-sheet`, is the test. If it looks wrong, STYLE.md changes, `art:board` rebuilds and the board is republished. | | 8 | Correctness | The board's local preview first showed **Ludus**: ports 5180 and 5191 were taken on this machine. | **Fixed** for the preview (port 5237, checked free). It affected only this review's look at the page, not the board. Lesson: `technical.md`. | | 9 | Scope | The garden layers assume a horizon at 40 % and a bed at 72 %. Phase 1's screen design may want other numbers. | **Accepted**: the numbers are in the manifest, so changing them costs a rebuild and new pictures, which is the reason to decide before Mark makes the layers. Noted for the Phase 1 feature doc. | | 10 | Offline | The board needs the network; the game doesn't. | **Not applicable to the player**: the board is a tool. `art/final/` ships inside the precached bundle (Phase 1). | diff --git a/HANDOVER.md b/HANDOVER.md index eb954bc..ce57d19 100644 --- a/HANDOVER.md +++ b/HANDOVER.md @@ -26,7 +26,7 @@ Rewritten at the end of each session (CLAUDE.md §5.1). appears in the garden, and the page opens at `#letter`, offline too. Review: [`.agents/reviews/feature-letter-slot.md`](.agents/reviews/feature-letter-slot.md). - **The art pipeline and the art board:** merged to `main`. [`docs/ART.md`](docs/ART.md) is the - pipeline. [`art/STYLE.md`](art/STYLE.md) is a draft for the author. [`art/manifest.json`](art/manifest.json) + pipeline. [`art/STYLE.md`](art/STYLE.md) is approved by the author (2026-11-01, S1–S5 kept as drafted). [`art/manifest.json`](art/manifest.json) lists 25 Phase 1 pictures, with 29 stand-ins in `art/placeholders/`. `tools/art-prep` builds prompts and the board (`pnpm art:board`) and moves accepted pictures into `art/final/` (`pnpm art:accept`). The board is published, private: @@ -45,8 +45,7 @@ The notification decision is made: in-app only on the web (G0.26). door to real help (G0.27), and Q9 (may the letter name the book). 2. **Sentences:** an agent may propose public-domain candidates with their sources. Only the author can mark one verified. -3. **Art:** read `art/STYLE.md` §0 (S1–S5) and approve or change the style. Then make - `rose-sheet` on the board and accept it. That is the first step of the Phase 0 art gate. +3. **Art:** the style is approved. Make `rose-sheet` on the board and accept it. That is the first step of the Phase 0 art gate. After an accept, Claude reads the row (`ArtifactData get art/`), downloads the picture (`Artifact read` with the asset id as `path`), runs `pnpm art:accept`, commits on `art/`, and writes `final` back into the row. diff --git a/art/STYLE.md b/art/STYLE.md index 447d05f..ceb895f 100644 --- a/art/STYLE.md +++ b/art/STYLE.md @@ -5,16 +5,16 @@ The style system prompt for every picture in Rosea Domi. The pipeline that uses word, then adds the picture's own part, generated from [`manifest.json`](manifest.json). A picture that is off-style goes back for another try. It is never shipped. -> **Draft, 2026-11-01 — waiting for Mark.** Claude wrote this draft from CLAUDE.md §1 and -> GAMEPLAY.md. The roadmap says STYLE.md is drafted *with Mark*. The open choices are listed in -> §0. The first picture on the board, the rose's character sheet, is the test. If it looks -> wrong, this file changes before anything else is made. +> **Approved by Mark, 2026-11-01.** Claude drafted this file from CLAUDE.md §1 and GAMEPLAY.md, +> and Mark kept the draft as it was: S1–S5 in §0 are decided. The first picture on the board, +> the rose's character sheet, is still the test. If it looks wrong, this file changes before +> anything else is made, and `pnpm art:board` rebuilds every prompt. --- -## 0. Open choices for Mark +## 0. The choices, decided 2026-11-01 -| # | Choice | The draft says | Why | +| # | Choice | Decided | Why | |:--|:--|:--|:--| | S1 | The medium | Matte gouache on warm paper, with soft brush outlines | It is gentle and hand-made like the rest of Domi. It is also clearly not the book's look, which is a thin pen line with loose, pale watercolour. | | S2 | Where the rose lives | A small garden bed on a hillside meadow, with a low dry-stone wall and a wide sky to the west | The sunset is real, so the scene needs a real horizon. It is an ordinary garden, never a tiny planet. | diff --git a/docs/ART.md b/docs/ART.md index 4edd0ec..ca311da 100644 --- a/docs/ART.md +++ b/docs/ART.md @@ -3,8 +3,8 @@ Every illustration in Rosea Domi goes through this pipeline. A picture that skipped a step is not shipped, however good it looks (CLAUDE.md §7). -- **What the pictures look like:** [`art/STYLE.md`](../art/STYLE.md). It is a draft until Mark - approves it. +- **What the pictures look like:** [`art/STYLE.md`](../art/STYLE.md). Mark approved it on + 2026-11-01 (S1–S5 in its §0). - **Which pictures exist:** [`art/manifest.json`](../art/manifest.json), Phase 1 first. - **The tools:** [`tools/art-prep/`](../tools/art-prep/). It turns those two files into prompts, stand-ins and the board, and moves accepted pictures into `art/final/`. From e0cbfc466af263d69bceec7797b0c274918bf671 Mon Sep 17 00:00:00 2001 From: mnovak Date: Sun, 1 Nov 2026 21:31:34 +0100 Subject: [PATCH 2/2] [engine] PurityLint: Load ESLint once in beforeAll so a cold start under load cannot time out the first case --- .agents/lessons/README.md | 2 +- .agents/lessons/testing.md | 15 +++++++++++++++ packages/engine/test/purity-lint.test.ts | 8 +++++++- 3 files changed, 23 insertions(+), 2 deletions(-) diff --git a/.agents/lessons/README.md b/.agents/lessons/README.md index e5764cd..5799f73 100644 --- a/.agents/lessons/README.md +++ b/.agents/lessons/README.md @@ -12,7 +12,7 @@ and **how to apply it**. | [`art.md`](art.md) | 2 | The image pipeline. | | [`code.md`](code.md) | 2 | TypeScript, Svelte, async ordering, Rust. | | [`technical.md`](technical.md) | 5 | The browser and the build as platforms. | -| [`testing.md`](testing.md) | 4 | What makes a test worth having, and how a passing test lies. | +| [`testing.md`](testing.md) | 5 | What makes a test worth having, and how a passing test lies. | | `privacy.md` | none yet | What could leave the device or make a person findable. (The geocell finding is in the review, not here: it was caught before it cost anything.) | | [`process.md`](process.md) | 2 | Workflow, commits, credentials, honesty about what shipped. | diff --git a/.agents/lessons/testing.md b/.agents/lessons/testing.md index 608f059..ce2c3d1 100644 --- a/.agents/lessons/testing.md +++ b/.agents/lessons/testing.md @@ -58,3 +58,18 @@ arrives. Then it fails for the first time on the author's machine, with the auth **How to apply it.** When a test branches on content that does not exist yet, fill the content temporarily, run the suite, restore it, and record the run in the review. + +## A one-time cold start is charged to the first case + +**What happened.** On 2026-11-01, with the machine at 80% CPU, `pnpm test` failed one engine +case: `purity-lint.test.ts` › *reports Date.now()*, timed out at 5 s. The snippet was fine. +The first `eslint.lintText` call loads the whole config and typescript-eslint, and vitest +charged that load to whichever case ran first. The fix is a `beforeAll` that lints an +empty file once, with its own 60 s timeout. + +**Why it bit.** A suite that passes on a quiet machine can still hide a fixed cost inside one +case. It fails only under load, and then it looks like a bug in the code that case tests. + +**How to apply it.** When the first case of a file loads something heavy (a linter, a +compiler, a browser), load it in `beforeAll` with an explicit timeout. If only the first case +of a file times out, suspect a cold start before suspecting the code. diff --git a/packages/engine/test/purity-lint.test.ts b/packages/engine/test/purity-lint.test.ts index 9e94c94..0832623 100644 --- a/packages/engine/test/purity-lint.test.ts +++ b/packages/engine/test/purity-lint.test.ts @@ -8,7 +8,7 @@ */ import { ESLint } from 'eslint'; import { fileURLToPath } from 'node:url'; -import { describe, expect, it } from 'vitest'; +import { beforeAll, describe, expect, it } from 'vitest'; const repoRoot = fileURLToPath(new URL('../../..', import.meta.url)); const eslint = new ESLint({ cwd: repoRoot }); @@ -42,6 +42,12 @@ const IMPURE: readonly [what: string, code: string][] = [ ]; describe('engine purity lint rule', () => { + // The first lint loads the config and typescript-eslint. On a busy machine that + // alone took over vitest's 5 s, failing whichever case ran first. Pay it here. + beforeAll(async () => { + await messages('export {};', ENGINE_FILE); + }, 60_000); + it.each(IMPURE)('reports %s inside packages/engine/src', async (_what, code) => { const found = await messages(code, ENGINE_FILE); expect(found.filter((m) => m.startsWith('fatal')), 'snippet must parse').toEqual([]);