- commit
- 6a711794180dfae5ff712b8b017352e9ee1fb916
- parent
- 7b2d4982b8ffd6e0085fe205b611808ef30b8586
- author
- Dami <dami.etoile@gmail.com>
| M | openspec/ | 11 | +++++++++-- |
| M | openspec/ | 4 | ++-- |
@@ -59,5 +59,12 @@ prior `getLevels().find(...)` path on the same local run (65.2×). The latter
5959 comparison includes the old full-list cloning cost; it is an architecture6060 comparison, not a frame-time claim. The full Node suite passed 373/373,6161 production build passed, and the world-index and pack/share browser flows62-passed without console or page errors. Delayed-win replacement/removal cases63-remain an explicit regression task before this change is archived.62+passed without console or page errors.63+64+The delayed Win handoff is guarded by both the stable level ID and the65+specific game instance that created the timer. This prevents a replacement66+pack from promoting an old solved game when it reuses the same local level ID,67+and prevents a removed pack from promoting after catalog fallback. Focused68+regression coverage in `tests/level-identity.test.js` covers the valid handoff,69+same-ID replacement, removal fallback, and undoing a win. The full Node suite70+passed 377/377 and the production build passed after this correction.@@ -13,7 +13,7 @@
1313 1414 - [x] 2.1 Migrate level loading, continue navigation, progress marking, and win1515 promotion to stable IDs while retaining numeric selection compatibility.16-- [ ] 2.2 Handle pack replacement/removal during delayed win and gift/workshop16+- [x] 2.2 Handle pack replacement/removal during delayed win and gift/workshop1717 handoffs without promoting a stale level.1818 - [x] 2.3 Verify solved progress remains keyed by pack and local level IDs after1919 registration order changes.@@ -22,7 +22,7 @@
2222 2323 - [x] 3.1 Add catalog tests for replace, remove, active fallback, clone safety,2424 direct reads, and cache invalidation.25-- [ ] 3.2 Add application tests for progress and delayed Win handoffs across25+- [x] 3.2 Add application tests for progress and delayed Win handoffs across2626 replacement/removal and reused local IDs.2727 - [x] 3.3 Run the focused catalog/application tests, full Node suite, production2828 build, and browser pack import/share flows.