Commit Graph
100 Commits
Author SHA1 Message Date
larssand be99cfaab2 feat(judging): judge finished heats, DSQ/DNF, reasons, own time and driver calls per EFRA (1.70.0) 2026-11-05 23:31:01 +01:00
larssand 2e3676d0cd docs(guide): team race, race overview, archive, practice ranking, speaker panel, sponsor flow and simulator (1.69.1) 2026-11-05 23:12:58 +01:00
larssand eb4c472ef9 feat(audio): speaker panel on Race Day and Judging with quick sound switches (1.69.0) 2026-11-05 22:50:00 +01:00
larssand 299fb45c6e test drivers och bilar 2026-11-05 22:40:46 +01:00
larssand a7d2d0b9ae feat(practice): open practice settings with ranking by best N in a row or best X minutes (1.68.0) 2026-11-05 22:38:33 +01:00
larssand 8a8b2417fd fix(events): easy setup first in Manage; manual heats and branding folded away (1.67.2) 2026-11-05 22:21:47 +01:00
larssand a9146d9662 fix(team-race): edit teams and length while the race runs; quick length picks (1.67.1) 2026-11-05 22:05:20 +01:00
larssand 37076b8490 feat(team-race): one team race setup panel with auto split, car per team and start checks (1.67.0) 2026-11-05 21:55:37 +01:00
larssand 69a65748ce feat(results): race overview on Race Day and an event-grouped results archive (1.66.0) 2026-11-05 21:44:06 +01:00
larssand 31ac04616a fix(overlay): show the heat's start list before the first passing (1.65.6) 2026-11-05 20:02:08 +01:00
larssand 54f4c3b923 fix(sync): retry failed saves every 5 s; restart the decoder simulator with the server (1.65.5) 2026-11-05 19:48:32 +01:00
larssand fed83ddf67 fix(audio): call a new leader only when the change is confirmed, not at every qualifying swap (1.65.4) 2026-11-05 19:38:37 +01:00
larssand 13f32fc0d6 fix(audio): generate count-down calls ahead of time with Piper so no number is skipped (1.65.3) 2026-11-05 19:33:10 +01:00
larssand 62ec97c9e9 fix(sim): connect to the simulator on page load even with auto-reconnect off (1.65.2) 2026-11-05 19:18:31 +01:00
larssand e682a2056c fix(decoder): reconnect attempts no longer save to the server, back off to 15 s (1.65.1) 2026-11-05 18:53:49 +01:00
larssand e4874fd558 feat(sim): start and stop the decoder simulator from Settings (1.65.0) 2026-11-05 18:48:37 +01:00
larssand 0ce7280cbf feat(sim): decoder simulator for testing without a decoder (1.64.0) 2026-11-05 18:37:36 +01:00
larssand d0a5df6992 feat(sponsor): quick setup with guest drivers, shared rental cars, rotating heats and A/B finals (1.63.0) 2026-11-05 18:31:57 +01:00
larssand 6142b14e47 feat(audio): quick lap time call at each passing, 17 six / 18 flat (1.62.0) 2026-11-05 18:14:30 +01:00
larssand 94ec278f53 feat(audio): practice hype calls and leader calls in qualifying and finals (1.61.0) 2026-11-05 08:19:45 +01:00
larssand f602778895 feat(audio): good pace call says the average of the steady laps (1.60.0) 2026-11-05 08:08:16 +01:00
larssand 12572ee31c fix(audio): speak lap times as seconds with hundredths, no leading zero (1.59.1) 2026-11-05 07:52:04 +01:00
larssand db6a9f19e4 fix(race): finish the lap you are on, one clock owner, edits survive refresh, participants editable (1.59.0) 2026-11-04 21:34:06 +01:00
larssand afb8829b16 fix(race-setup): wizard builds qualifying as Q/H heats; guide gets race day step by step (1.58.0) 2026-11-04 16:35:31 +01:00
larssand e1ca72db51 fix(results): same laps ranked by lowest total time, not closest to the set time (1.57.1) 2026-11-03 18:48:00 +01:00
larssand 221a06c899 feat(audio): 'starting to the sound of the tone' call, tone start and stop signal finish by default (1.57.0) 2026-11-03 11:41:33 +01:00
larssand a8aaeae02f feat(audio): trumpet start and fanfare finish by default, start/finish signal chosen in settings (1.56.0) 2026-11-03 09:26:19 +01:00
larssand 36fe1e3933 fix(audio): longer Piper time for long calls, fallback voice matches the line's language (1.55.2) 2026-11-03 09:16:11 +01:00
larssand c3aafba327 fix(audio): heat call in the announcer's language with spoken names only (1.55.1) 2026-11-03 09:11:32 +01:00
larssand 3425da4b8f feat(audio): air horn for start and finish, count 10..3 then quiet until the horn 1-3 s later (1.55.0) 2026-11-03 08:56:15 +01:00
larssand a8996c4195 fix(race-day): run again resets the current heat, not a stale copy; show the set time before the start (1.54.2) 2026-11-03 08:46:51 +01:00
larssand 8b625c3d64 fix(race-setup): ask before deleting a race or a session (1.54.1) 2026-11-02 08:48:37 +01:00
larssand d0248b1960 feat(race-day): fold run heats in today's schedule and mark the next heat (1.54.0) 2026-11-02 08:30:01 +01:00
larssand 73e3d1ff75 feat(race-setup): group a race's sessions per step, fold run steps, rare actions in a menu (1.53.0) 2026-11-02 08:26:00 +01:00
larssand b23410c190 feat(race-setup): group the race list into today, upcoming and folded done, with progress and search (1.52.0) 2026-11-02 08:21:17 +01:00
larssand b2e08db3d8 feat(race-day): call the next heat - asked by hand, automatic with the autopilot (1.51.0) 2026-11-01 22:25:43 +01:00
larssand fdc6c179dc feat(race-day): day schedule for all classes, autopilot, pause the day, printed running order and drivers' board (1.50.0) 2026-11-01 22:06:59 +01:00
larssand 0ba858d638 docs(roadmap): plan race day CSV export and results publishing to external sites 2026-11-01 21:44:42 +01:00
larssand bb0fa7ede4 feat(race-setup): list sessions in running order and move them with up/down (1.49.0) 2026-11-01 20:13:15 +01:00
larssand e199f3aa1a feat(series): correct a round's result by hand (1.48.0) 2026-11-01 19:50:20 +01:00
larssand 6142bceca9 fix(archive): name the winner from the session result, not the raw lap count (1.47.1) 2026-11-01 19:03:25 +01:00
larssand 54487a18a6 feat(race-day): live race for the race controller with order, laps, gaps and estimated finish (1.47.0) 2026-11-01 16:38:08 +01:00
larssand c4163441fc fix(race-day): keep local state while starting or timing a heat, keep count-down voice on time (1.46.1) 2026-11-01 16:16:46 +01:00
larssand 8d27072567 feat(qualifying): default to staggered start with most laps in time and best-3-laps seeding (1.46.0) 2026-11-01 12:18:24 +01:00
larssand b57e15b428 fix click on user to se training stats 2026-11-01 10:54:38 +01:00
larssand ab1c26a89b fix(race-day): reset a heat to ready with its clock at zero, keep recent races listed (1.45.2) 2026-11-01 10:49:17 +01:00
larssand 7376595001 fix(series): name the seeding column max drivers per seed group (1.45.1) 2026-10-31 22:59:45 +01:00
larssand e7eaa0561e feat(series): seeding practice in groups split on the series standings (1.45.0) 2026-10-31 22:52:18 +01:00
larssand 80e0c5308a docs(series): guide and README for seeding, heat order and next-step buttons (1.44.1) 2026-10-31 09:50:17 +01:00
larssand 71aa149a4d feat(series): next-step button per round and Race Day next session (1.44.0) 2026-10-31 09:03:34 +01:00
larssand dbda06d101 fix(series): report created races, delete a series with its races; group Race Day sessions by today's races (1.43.1) 2026-10-31 08:34:44 +01:00
larssand 74dbbf6ae0 feat(series): ÖRC Winter format, seeding practice and heat order when creating rounds (1.43.0) 2026-10-31 07:58:40 +01:00
larssand 40c3737925 test(overlay): every driver is listed, compact rows beyond 12 2026-10-25 21:33:54 +01:00
larssand 0cabe1f96f fix(overlay): show every driver, compact rows beyond 12 (1.42.6)
The overlay page cut the leaderboard at 12 drivers. It now shows all of
them, with compact rows when there are more than 12 so they fit on a TV.
2026-10-25 21:33:36 +01:00
larssand 2c2b16537e fix(practice): stop flagging a driver's faster pace as suspect laps (1.42.5)
Flagged laps never entered the reference pace, so a driver who got
faster had every lap flagged. They now count in the reference (last 10
laps), settled flags are released, and a flagged lap counts until it is
removed; Approve only drops the flag.
2026-10-25 21:20:17 +01:00
larssand 35eb3eb059 feat(decoder): warn when the decoder's clock is off (1.42.4)
The decoder's time is never changed. Passings (also during warm-up)
measure it against the computer's clock, and Race Day's preflight and
the decoder diagnostics warn when it is over a minute off, e.g. after
the switch to winter time.
2026-10-25 18:40:35 +01:00
larssand ca88fd9ecc fix(profile): open the mobile profile on the class driven last (1.42.3)
Passes and exercises only count the selected class, and the profile
opened on the first registered one, so laps with another car never
showed. It now opens on the class with the latest lap and offers a
switch when today's latest laps are in another class.
2026-10-25 18:01:40 +01:00
larssand 3eb4b5f042 fix(overlay): tidy the OBS tower header and rows (1.42.2)
The name no longer wraps beside the clock, position badges no longer
overlap names, the suspect flag sits inline, and the transponder line
is gone.
2026-10-23 08:21:23 +02:00
larssand 7d097fd531 chore(release): 1.42.1 2026-10-23 08:10:46 +02:00
larssand f51aa0ba37 fix(settings): make data imports real buttons and confirm the full import
The JSON imports were bare file inputs next to the export buttons and
didn't read as imports. They are now buttons like the CSV imports; the
full import asks before it replaces all race data.
2026-10-23 08:05:57 +02:00
larssand f4dc3bb5bd chore(release): 1.42.0 2026-10-22 13:26:13 +02:00
larssand 3f7f62bfa8 fix(security): refuse compressed request bodies
express.json decompressed Content-Encoding br/gzip/deflate bodies before
the PIN check, running Node's Brotli decoder on input from anyone who
can reach the port (CVE-2026-111497). The app never sends compressed
bodies, so they now get 415.
2026-10-22 13:19:59 +02:00
larssand 4def444202 feat(overlay): click a driver to open their training stats
In RaceCore's own overlay a driver row opens Training stats for that
driver and class; the stand-alone overlay window opens them in a new tab.
The public overlay gets no links: the mobile profile link is personal
and can write.
2026-10-22 10:05:24 +02:00
larssandandClaude Opus 5.5 cade201d5a feat(audio): fewer personal best calls in Open Practice
On fresh packs every driver beats their best almost every lap early in
the day. No call for a driver's first 10 laps since the practice started
or was reset, at most one per driver a minute, and 0.1 s over the last
called time. Adjustable under Settings → Audio; 0 turns a rule off.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-19 15:40:24 +02:00
larssandandClaude Opus 5.5 633e0efa1f feat(race-day): call the practice reset "Reset – new practice day"
"New practice day" didn't say that it resets. Also a test that several
resets of the same Open Practice (even the same day) keep every lap.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-19 08:38:43 +02:00
larssandandClaude Opus 5.5 2c6c37f6ca fix(decoder): connect even when the browser storage is full
A big installation outgrew the localStorage quota; saveState() threw
QuotaExceededError and, since connecting saves first, the decoder never
came online. The local copy is only a cache of the server state, so a
write that doesn't fit now drops it instead of throwing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-18 16:06:35 +02:00
larssandandClaude Opus 5.5 c8a797fe6f fix(race-day): bring back Reset data for race sessions
It went away with Timing's run controls; practice has New practice day,
heats and finals get Reset data on Race Day when not running.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-18 15:35:20 +02:00
larssandandClaude Opus 5.5 8120ebc1b5 feat(race-day): run buttons follow the race flags
Green starts or resumes, red pauses (stops the race), checkered finishes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 18:50:40 +02:00
larssandandClaude Opus 5.5 ba35f9e7d2 feat(race-day): traffic-light colours on the run buttons
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 18:45:21 +02:00
larssandandClaude Opus 5.5 c4df90706a feat(ux): run sessions from Race Day with quick actions
Race Day gets Start practice, New track layout and Create race, a session
picker, only the buttons that apply, and New practice day (replaces Reset
data on Timing; laps stay in the training stats). Timing is for following
and links to Race Day. The Dashboard shows the three common tasks first.
Guide, READMEs, screenshot and the "Run a session" video follow the flow.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 18:32:01 +02:00
larssandandClaude Opus 5.5 3a6789f42f fix(timing): keep timing the running session when another one is selected
Passings and the session clock followed only the selected session, so
selecting another practice or the next heat while one was running
dropped every lap. They now go to the running session, and Timing and
Race Day show where laps are being recorded.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 17:31:59 +02:00
larssandandClaude Opus 5.5 cdde070c1c fix(settings): connect to the decoder URL shown in the field
Connect now used the saved URL even after a new one was typed; typed
decoder URLs are now saved first. Adds a browser test for saving a new
decoder port and connecting.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 17:23:48 +02:00
larssandandClaude Opus 5.5 abed53fb32 docs(readme): restructure both READMEs and cover every current feature
Contents, highlights and quick start first, then features in the order
a club uses them, then installation, decoders and development. Adds the
start count-down, series hub, practice tooling, audio, OBS and security
features, and removes outdated statements.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-13 07:44:23 +02:00
larssandandClaude Opus 5.5 72d83ad183 feat(overlay): show places gained since the start in the OBS tower
Heats and finals started together show ▲/▼ against the start order
(new OBS option, on by default). In practice the best lap is no longer
printed twice as both result and best.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 20:13:10 +02:00
larssandandClaude Opus 5.5 533f59adf9 feat(settings): one public address (domain / DynDNS) for all mobile profiles
Moves the public address from each driver's share panel to Settings ->
System & backup, with Save and Detect public IP. The share panel shows
the address in use and links to the setting; empty keeps using the
local network address.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 19:45:53 +02:00
larssandandClaude Opus 5.5 42e53fd356 docs(guide): add a Series / cup tab to the in-app guide
Explains creating a series, running each round from the series page,
points and standings, and a worked winter-series example.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 19:31:19 +02:00
larssandandClaude Opus 5.5 b5707f92d1 feat(series): run each round from the series page
Step 3 becomes a rounds table: pick drivers inline (copy from the
previous round, add a late entry), set qualifying rounds/finals/max
cars per heat per round, see the status, and create qualifying and
finals from there. Qualifying heats are now split evenly so nobody
drives alone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 18:55:36 +02:00
larssandandClaude Opus 5.5 581ec2c781 fix(series): clearer step layout, sorted class list and autosave
The series page is split into numbered steps; classes are a sorted list
with the tick on the left and All/None, new series start with none, and
every change is saved straight away so ticks are no longer lost. Also
gives primary/danger buttons white text in the light theme.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 18:28:05 +02:00
larssandandClaude Opus 5.5 ec200aef2b feat(series): choose open series or club members only for series points
Who scores is now an explicit per-series choice: every driver (default)
or club members only, with the club field shown only for the latter.
Series saved with a club keep members-only scoring. README updated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-11 18:12:18 +02:00
larssandandClaude Opus 5.5 efa082c2b5 fix(training): keep a linked driver until the first server load finishes
A ?driver= link to Training stats was cleared when the page rendered
from the local copy before the server data arrived. The selection now
survives until the first load settles, then the driver opens.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 20:21:19 +02:00
larssandandClaude Opus 5.5 af79b610db feat(training): base training stats on practice, keep race laps separate
Training stats count Open/Free practice by default; laps from
qualifying, heats and finals are kept and shown under Based on: Races
or All, marked with race, session and series. Races are listed per race
session and never split into stints. Same picker in the mobile profile.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 20:08:17 +02:00
larssandandClaude Opus 5.5 9a9379aa83 feat(series): add series/cup championships with points tables and standings
Group any number of races in freely chosen classes into a series with a
points table (ÖRC/100-80-70/F1/custom), best-N or drop-X counting, a
club filter that re-ranks members without guests, tie-breaks, rounds
created from a date list, and per-class standings with print and PDF.

Also fixes PDF export of wide tables: they are compacted and switched
to landscape instead of truncating names and dropping columns.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-10 19:49:23 +02:00
larssandandClaude Opus 5.5 f65e526948 feat(drivers): test a driver's spoken name and keep search focus while typing
Adds a Test pronunciation button (forms and list) that plays the
passing sound and real announcements with the spoken name through race
audio. Fixes the Drivers/Cars search losing focus after one letter.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-08 08:35:47 +02:00
larssandandClaude Opus 5.5 a13c9a15f9 feat(judging): keep penalties and race lap changes in the Judging view only
Race sessions: Timing driver details become read-only with an Open in
Judging button; penalties and lap changes happen only in Judging.
Practice: no penalties anywhere, per-lap clean-up stays on Timing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 21:20:03 +02:00
larssandandClaude Opus 5.5 7f267e17fe fix(settings): open the right Settings tab from the update link and Race Day
The sidebar update notice now lands on System & backup at Updates, and
Race Day's decoder/backend/audio fix buttons open the matching tab,
instead of whichever tab was used last.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 20:44:28 +02:00
larssandandClaude Opus 5.5 9d79bcb4d3 feat(layouts): optional min/max lap time per track layout for practice
Each layout can carry its own lap window (set on creation, editable in
Settings, saved from Race Day during practice). Open/Free practice on
that layout uses it; races always keep the event's values.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 20:33:22 +02:00
larssandandClaude Opus 5.5 8601954ea2 feat(practice): flag suspiciously short laps and remove any lap in one click
Practice laps under 85% of the driver's own median (a likely shortcut)
are flagged: counted, but never a best lap, record or training stat
until approved. Timing and Race Day get a one-click Approve/Remove
panel, overlays show a warning mark, and any lap can be removed or
restored from Timing and Judging with undo.

Also sends judge corrections straight to the server so its hot-results
protection can no longer hold back a correction made right after a
passing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 19:53:23 +02:00
larssandandClaude Opus 5.5 3cc4fa0845 fix(training): keep practice laps in training stats after Reset data
Resetting a running Open Practice deleted its results, the Timing view
recreated an empty result at once, and the next save rebuilt that
session's training laps from nothing - wiping every earlier lap from
the drivers' stats. Reset now syncs first and records resultsResetAt;
laps from before it are kept.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 23:13:58 +02:00
larssandandClaude Opus 5.5 8b63dd2372 fix(lap): keep best laps per track layout and count the current session for records
A layout switch during a running open practice kept every driver's
old-layout best lap, blocking personal-best calls and skewing the
practice leaderboard. Best laps now restart on a new layout and each
lap records its layout. The track record baseline now includes the
current session so the same record isn't called twice.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 21:14:19 +02:00
larssandandClaude Opus 5.5 ebd0f74f40 feat(audio): add downloadable extra Piper voices with accents
Adds Alma (sv), Alan, Northern English, Cori, Alba (British/Scottish)
and Joe, John, Norman (American) as optional voices downloaded one at
a time from Settings, with gender (measured pitch) and accent shown in
the voice lists. The standard install is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 21:58:08 +02:00
larssandandClaude Opus 5.5 aaca5e8c63 feat(audio): passing tone only during races and remove legacy audio
Adds 'Calls during a race' (default: passing tone only, like timing
systems) that drops name/personal best/leader/position calls in race
sessions; practice keeps them. Removes the legacy audio panel and
fallbacks, including its 'Sound on' switch that silently muted every
race-audio voice.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 21:47:40 +02:00
larssandandClaude Opus 5.5 5bfb67ea02 feat(race-day): start heats with an EFRA/IFMAR count-down and flying start
Race Day Start now runs a count-down (Go, 30 s - 5 min, default per
event) with calls every minute, 30 s and 10 s, grid call and 9..3
count for grid starts, hold/resume/+1 min/to 30 s/to 10 s/Go now, and
starts the heat by itself when it runs out. The transponder check runs
during the count-down, replacing the separate warm-up.

Adds a flying start mode (horn + clock is running, own clock per car)
as the qualifying default, and the latest personal clock start rules
from EFRA 9.3 / IFMAR 4.2.3 for flying and staggered starts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 21:27:20 +02:00
larssandandClaude Opus 5.5 1bc75f8ec1 feat(race-day): add warm-up transponder check before a heat
Race Day gets a 1-3 minute warm-up per heat with a green check per
driver when their transponder is seen, countdown announcements
(sv/en), quick transponder fix from the panel, and a start warning
that still allows starting when someone is missing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 20:47:15 +02:00
larssandandClaude Opus 5.5 627179b95a feat(layouts): switch track layout mid-practice and view stats per layout
A club can run one Open Practice all season and re-lay the track now and then.
Previously a session's layout was frozen at start and every training lap inherited
it, so a season-long practice stayed on its first layout forever, and changing layout
was hidden under Settings -> Appearance.

- Each practice lap now counts toward the layout active when it was driven; a running
  practice session moves onto a new layout when one is added
- "New layout" strip on Training stats, Race Day and the Dashboard, offered only around
  practice; a running race session blocks layout changes everywhere
- "Stats for" selector (current / older layout / before layouts / all layouts) on
  Training stats and in the driver's mobile profile (?layout= on the public API)
- A layout that has practice laps on it can no longer be deleted
- Fix: the buildDriverTrainingStats wrapper in app.js dropped extra arguments

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-27 21:24:44 +02:00
larssandandClaude Opus 5.5 196437d25b feat(audio): choose a male or female local voice per language
The installer now fetches one male and one female Piper voice per language (Swedish
NST/Lisa, English Ryan/Lessac), with genders confirmed by measuring each voice's pitch
rather than guessed from the name. Settings -> Audio gets a voice selector per language
with its own Test button that always plays the Piper voice. Male is preselected for both.

The integration test now runs its server with an empty home directory, so voices
installed on the developer's own machine can't leak into it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-27 20:29:59 +02:00
larssandandClaude Opus 5.5 e8a2799a92 feat(audio): add offline local neural voice via Piper (sv + en)
Announcements can use Piper, a free local neural TTS, instead of the browser's system
voice. No account, no paid service, and it keeps working with no internet at the track.

- npm run tts:install (or Settings -> Audio -> Install) downloads the standalone Piper
  release for Linux/Windows/macOS plus Swedish and English voices into piper/ once
- server/tts.js generates each line once, one at a time, and caches it as WAV under
  data/tts/; a new line takes ~0.3 s with the standalone build
- src/piper_speech.js plays it and falls back to the browser voice if Piper is missing,
  errors, or takes over 2.5 s, so no announcement is lost and timing is never held up
- "Pre-generate phrases and driver names" renders every fixed phrase and name in both
  languages before race day

Browser voice stays the default. Generation routes fall under the admin PIN.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-27 19:28:15 +02:00
larssandandClaude Opus 5.5 9016ce02e4 feat(auth): add optional admin PIN for all API writes
Off by default. Once a PIN is set in Settings -> System & backup, every non-GET /api/*
request (plus GET /api/ammc/config) needs a signed 30-day HttpOnly cookie, which also
closes the unauthenticated /api/update/run restart trigger. A 401 opens a PIN dialog
and the pending save is retried after login. Reads stay open because the public overlay
hydrates through GET /api/state. Optional RC_ADMIN_ALLOWED_CIDRS restricts the same
routes by client address.

The PIN hash and signing secret live in data/, outside the app_state blob, so they
never leak through GET /api/state, exports or backups.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-24 22:14:58 +02:00
larssandandClaude Sonnet 5 bcd6e12a6c Document a concrete auth design for the deferred permissions work
Planning only, no code yet. Per-role PIN codes (not named accounts - a shared
trackside laptop doesn't want individual logins), an optional IP/host allowlist as a
separate complementary layer, and 2FA deliberately left out unless a club actually
exposes the server past their own LAN. Flags one open question for the user to decide
before implementation starts: auth off by default vs. on by default with an
auto-generated Admin PIN on first run.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-12 20:28:07 +02:00
larssandandClaude Sonnet 5 ae445097b0 Re-run the security audit against everything shipped since 2026-08-28
npm audit stays clean (0 vulnerabilities). Checked every new db.prepare()/spawn()/
execFileSync() call added since the last audit for injection risk - none found, all
parameterized SQL and array-form process args. Confirmed the CORS/security-header
middleware still covers every route added since, including the new ones.

One new notable finding: POST /api/update/run unconditionally stops the server before
checking whether an update is even available, making it a more direct denial-of-service
primitive than the app's other already-documented unauthenticated endpoints. No code
change made - tracked alongside the deferred permissions/auth work.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-12 20:22:31 +02:00
larssandandClaude Sonnet 5 922bd704eb Split the Guide page into tabs, matching the Settings/Event Manager pattern
The page had grown to ~20 stacked panels on one very long scroll - the same problem
already fixed twice this session for Settings and Event Manager. Grouped into 5 tabs
(Getting started, Create a race, Run a race, Training & results, Video guides) using
the same activeGuideTab-as-module-state approach so the selection survives an in-place
re-render (e.g. a language switch). The always-visible overview cards at the top are
unchanged.

Also investigated a "feels slow" concern raised alongside this: measured the page's
actual render cost in a real browser (median 0.6ms, on par with or faster than Settings/
Timing) and confirmed the periodic tickClock/updateSyncStatus intervals never re-render
an idle Guide page. No performance issue found - the perceived slowness was the page's
length, which this change addresses directly.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-12 19:59:15 +02:00