Skip to content

Sb/2c token health - #108

Merged
over2take merged 2 commits into
feature/system-builderfrom
sb/2c-token-health
Sep 29, 2026
Merged

over2take merged 2 commits into
feature/system-builderfrom
sb/2c-token-health

Conversation

@over2take

Copy link
Copy Markdown
Owner

Summary

Test plan

  • Tested locally
  • Tests pass

Pre-merge checklist

Code quality:

  • Code follows project style
  • No breaking changes (or clearly documented)
  • No console errors or warnings

Version & Release:

  • Version bumped? If releasing to users, update:
    • frontend/package.json version
    • docker-compose.yml APP_VERSION
    • CHANGELOG.md with release notes
  • GitHub Actions will auto-tag Docker images with the new version

Before merging to main:

  • All tests passing
  • PR reviewed and approved
  • Branch is up to date with main
  • No merge conflicts

Related issues

Developer added 2 commits September 29, 2026 16:26
… defense and injuries

The token's columns keep the running system's values, so combat, damage, the
health monitor and linked sheet fields are unchanged; the other systems' values
wait in token_vitals. tokens/vitals.js switchSystem swaps them and writes
game_system in one transaction, reading the system being left inside it, so a
failure or two quick switches can never split tokens from the setting. The
system picker route uses it and has every screen redraw; the generic settings
route can no longer change game_system or the migration markers.

A one-time start (startup/tokenVitals.js, adds rows only, run once) saves each
token's current values under every system it could be shown in. Map clears and
loads drop saved values for tokens that are gone, since they wind the id
sequence back.

Tests mutation-checked (restore, transaction, systems, settings guard, prune).
Verified on a read-only copy of the real database: 18 tokens switched away and
back came back identical.
…own folder

It matched the folder name MapSystem, which is only in a Windows checkout's
path: on the CI runner it cleared nothing, the second open of db.js returned
the first, closed connection, and the test failed with "Database is closed".
It now matches the backend directory as resolved, says so plainly if db.js was
not cleared, and waits for the first open's startup work (tokens/vitals
whenReady) before closing it.
@over2take
over2take merged commit 3d8f293 into feature/system-builder Sep 29, 2026
8 checks passed
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.

1 participant