Add simplified Open Practice flow and reorganize

This commit is contained in:
larssand
2026-08-24 19:25:21 +02:00
parent 5a6e51c51b
commit 2e6866a013
13 changed files with 481 additions and 55 deletions

View File

@@ -294,6 +294,7 @@ Owns:
- team normalization
- race presets
- race wizard defaults and session generation
- practice-only Open Practice event/session generation
- sponsor round generation
- event drivers / teams / team driver pool
- qualifying/finals generation and bumps
@@ -1013,6 +1014,7 @@ Why fragile:
High-risk functions:
- `normalizeEvent(...)`
- `buildRaceFormatConfigFromForm(...)`
- `buildOpenPracticeBundle(...)`
- `getEventDrivers(...)`
- `getTeamDriverPool(...)`
- `generateQualifyingForRace(...)`
@@ -1419,9 +1421,12 @@ Practical normalized shape:
participantsConfigured: boolean,
finalsSource: "practice" | "qualifying",
teams: RaceTeam[]
practiceOnly: boolean
}
```
`practiceOnly: true` identifies the simplified Open Practice flow. It deliberately has no class scope or configured participants, uses an `open_practice` session, ignores `durationMin` in timing logic, and must not require qualifying/finals in race summary warnings.
### `RaceTeam`
```js
@@ -2075,6 +2080,7 @@ npm test
`tests/race_timing_logic.test.js` covers:
- race-format parsing, defaults, lap limits, participants, and teams
- practice-only Open Practice bundle creation and persisted mode markers
- wizard generation of practice, qualifying, and team-race sessions
- qualifying heat generation and manual-grid-safe reseeding
- final generation, reserved bump slots, and bump-up promotion