Skip to content

Check the error table against Chronicle; send bare icon names; refresh docs - #130

Merged
keyxmakerx merged 1 commit into
mainfrom
claude/project-thread-6hatzh
Oct 3, 2026
Merged

keyxmakerx merged 1 commit into
mainfrom
claude/project-thread-6hatzh

Conversation

@keyxmakerx

@keyxmakerx keyxmakerx commented Oct 3, 2026 •

Copy link
Copy Markdown
Owner

Requested by Key Maker · project thread

Fixes #91
Fixes #105
Fixes #89
Fixes #88
Security implication: none. CI check and docs; the icon change only normalises a value Chronicle already normalises.
Consumer-verified: Chronicle internal/plugins/foundry_vtt/error-catalog.json (the check reads it live); Chronicle internal/sanitize/icon.go NormalizeIcon (style tokens fa-solid/fas/fa-regular/far/fa).
Foundry compatibility: n/a for runtime behaviour (the wizard sends a different string; nothing renders differently). node --check scripts/import-wizard.mjs passes.
Mockup: n/a. Nothing on screen changes.

What this changes

  • Add the queued CI check that the error-code table matches Chronicle #91: a new workflow, check-error-catalog.yml, fetches Chronicle's error-catalog.json from main on every PR, push to main and weekly. It fails when API-CONTRACT.md's error table (codes, categories, HTTP status) or update-info.mjs's CHRONICLE_CATEGORIES drift from it, or when schemaVersion changes. The comparison is pure (tools/_error-catalog-check.mjs) and unit-tested offline. A test also proves the real table and category set still parse, so the live check can't pass by reading nothing. The "implicit schema v1, no schema_version field" line was already wrong: the catalog carries "schemaVersion": 1.
  • Import wizard: send bare icon names #105: the import wizard sends fa-circle, not fa-solid fa-circle, and strips a leading style token before sending (scripts/_icon-name.mjs). The issue's third bullet (show Chronicle's 400 on the form) is moot: the new-category form has no icon field, so the icon is always the default and an icon 400 can't happen.
  • Bring TESTING.md up to date: the dashboard and map sections describe removed features #88: TESTING.md now lists the dashboard's 11 tabs behind the grouped rail. It replaces the Scene-notes and scene-linking map steps with journal map viewer steps, including a player-visibility section: a dm_only marker, user-restricted items, hidden tokens and fog never reach a player, checked in the viewer and in the page flags. It also replaces the hand-written-adapter checks with generic-adapter ones.
  • Docs drift: Scene-pins map model, a closed worldstate gap, CONSTANTS.md, the release process, the PR template test command #89: most items were already fixed on main. What remained:
    • GET /sync/mappings shows the real SyncMapping shape plus paging (checked against Chronicle's sync handler).
    • Two resolved rows are dropped from the field-discrepancy table.
    • The stale worldstate claim and the "Chronicle sends no calendar.* WS messages" claim are corrected (Chronicle's routes.go maps them; calendar-sync.mjs routes them).
    • The "dnd5e/pf2e have hand-written adapters" claim is corrected (only generic-adapter.mjs exists).
    • CONSTANTS.md's file:line refs become identifier names, and its scene wording is fixed.
    • README's map line is updated.
    • The PR template, tab count, admin path, compatibility range and release process were already right.

Why

These are housekeeping issues from the September inventory. TESTING.md has to be current before the live Foundry v14 session in #94.

Found while doing this and filed rather than fixed: #129. The import wizard still has a scene-to-map linking step, which the journal map viewer no longer uses. Changing it is visible, so it needs a mockup.

Test plan

  • node --test tools/test-*.mjs: 1008 tests, 1008 pass (adds test-error-catalog.mjs, 9 tests, and test-icon-name.mjs, 5 tests)
  • node tools/check-error-catalog.mjs passes against the live catalog and against a local Chronicle checkout
  • node tools/check-package-descriptor.mjs passes
  • Manual verification in Foundry: the TESTING.md wording for a few toasts and the flag shape are taken from the code; the Live test session on Foundry v14 (after TESTING.md is brought up to date) #94 live run confirms them
  • CI passes

Tenet self-check

  • T-B1 security: n/a; TESTING.md gains an explicit dm_only-never-reaches-a-player check
  • T-B2 plugin isolation: changes stay in the module
  • T-B3 production UI: no UI change
  • T-B4 dual-audience docs: docs describe current behaviour, present tense

Generated by Claude Code

…h docs

- CI fetches Chronicle's error-catalog.json and fails when API-CONTRACT.md's
  error table or update-info.mjs's category set drift from it (also weekly).
- The import wizard sends category icons as the bare name Chronicle stores.
- TESTING.md: the dashboard's 11 tabs and the journal map viewer replace the
  removed tab list and Scene-notes map steps, with a player-visibility check.
- Docs drift: GET /sync/mappings shape, resolved field-discrepancy rows,
  worldstate and calendar WS claims, adapters, CONSTANTS.md references.

Fixes #91
Fixes #105
Fixes #89
Fixes #88

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WURTwLzEdwXRLKXnnQtFCS
@keyxmakerx keyxmakerx self-assigned this Oct 3, 2026
@keyxmakerx
keyxmakerx marked this pull request as ready for review October 3, 2026 15:33
@keyxmakerx
keyxmakerx merged commit 1003636 into main Oct 3, 2026
3 checks passed
@keyxmakerx
keyxmakerx deleted the claude/project-thread-6hatzh branch October 3, 2026 15:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment