[P3] Suunto SDM XML with no dives imports silently and bypasses the 200-dive limit #38

Closed
opened 2026-10-27 02:59:42 +00:00 by pedro · 1 comment
Owner

Priority: P3
Type: bug
Source: project review requested 2026-10-26 (second pass)

Location: src/diveExportImport.ts:53-54, 417-418

Problem and evidence

parseSuuntoSDM maps every MSG without a count check, and the non-ZIP path returns parser output directly. <SUUNTO></SUUNTO> returns [] and the import view shows no dive and no error; a file with 250 MSG blocks returns 250 dives, unlike UDDF and SDE which enforce 1–200.

Suggested correction

Apply the same 1–200 dive check to plain XML imports.

Acceptance criteria

Regressions for empty and oversized SDM files; existing import tests pass; pnpm verify passes.

Scope: maintenance of the educational simulator. Preserve historical R1 acceptance and operational-validation limits.

Priority: P3 Type: bug Source: project review requested 2026-10-26 (second pass) Location: `src/diveExportImport.ts:53-54, 417-418` Problem and evidence parseSuuntoSDM maps every MSG without a count check, and the non-ZIP path returns parser output directly. `<SUUNTO></SUUNTO>` returns [] and the import view shows no dive and no error; a file with 250 MSG blocks returns 250 dives, unlike UDDF and SDE which enforce 1–200. Suggested correction Apply the same 1–200 dive check to plain XML imports. Acceptance criteria Regressions for empty and oversized SDM files; existing import tests pass; pnpm verify passes. Scope: maintenance of the educational simulator. Preserve historical R1 acceptance and operational-validation limits.
Author
Owner

Fixed on maintenance/review-2026-10-27 in 41a7bb1 — PR #40.

Empty plain imports and >200 SDM messages report errors; valid multi-dive SDM still loads. Browser regression (DOMParser needed).

Branch verification: pnpm verify 145 tests and release budgets; Chromium/Firefox/WebKit review, replay, compatibility and offline lifecycle checks; CI verify runs #111/#112 pass. Record: docs/MAINTENANCE-2026-10-27.md. Closes on merge of PR #40.

Fixed on `maintenance/review-2026-10-27` in `41a7bb1` — [PR #40](https://git.guresky.com/pedro/DiveSim/pulls/40). Empty plain imports and >200 SDM messages report errors; valid multi-dive SDM still loads. Browser regression (DOMParser needed). Branch verification: `pnpm verify` 145 tests and release budgets; Chromium/Firefox/WebKit review, replay, compatibility and offline lifecycle checks; CI verify runs #111/#112 pass. Record: `docs/MAINTENANCE-2026-10-27.md`. Closes on merge of PR #40.
pedro closed this issue 2026-10-27 05:39:05 +00:00
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: pedro/DiveSim#38
No description provided.