On https://flight.dev.kkhost.pl/ speedup is still x1000, not x24 #135

Closed
opened 2026-09-23 08:21:28 +02:00 by kamilkrzywda · 1 comment
Owner
No description provided.
Author
Owner

Shipped as v0.62.0 (PR #138, merged 673365f, tag v0.62.0). The world clock now runs at exactly WORLD_TIME_SCALE = 24 while any plane is flying or in repair and stays frozen when the whole fleet is grounded — regardless of legacy stored timeScale values.

Root cause of the live ×1000: production docker-compose.yml set FLIGHT_TEST_HOOKS: "1" (which also enabled the /api/test/* hooks in prod) AND a pre-v0.52.0 save held timeScale: 1000, which the hook path honored. Fix: env gate in lib/sim/engine.ts tickOnce — scale = FLIGHT_TEST_HOOKS === '1' ? sim.timeScale : WORLD_TIME_SCALE; removed FLIGHT_TEST_HOOKS from prod compose (CI's docker-compose.ci.yml sets it itself, so e2e is unaffected). No DB migration needed. Unit tests pin both rate branches; e2e pins the exact freeze and exact clock equality across container restarts. CI green (run 190), deployed to prod, verified /api/version = 0.62.0.

Shipped as v0.62.0 (PR #138, merged 673365f, tag v0.62.0). The world clock now runs at exactly WORLD_TIME_SCALE = 24 while any plane is flying or in repair and stays frozen when the whole fleet is grounded — regardless of legacy stored timeScale values. Root cause of the live ×1000: production `docker-compose.yml` set `FLIGHT_TEST_HOOKS: "1"` (which also enabled the /api/test/* hooks in prod) AND a pre-v0.52.0 save held `timeScale: 1000`, which the hook path honored. Fix: env gate in `lib/sim/engine.ts` tickOnce — `scale = FLIGHT_TEST_HOOKS === '1' ? sim.timeScale : WORLD_TIME_SCALE`; removed FLIGHT_TEST_HOOKS from prod compose (CI's docker-compose.ci.yml sets it itself, so e2e is unaffected). No DB migration needed. Unit tests pin both rate branches; e2e pins the exact freeze and exact clock equality across container restarts. CI green (run 190), deployed to prod, verified /api/version = 0.62.0.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: OpenCode/Flight-Ops#135