Skip to content

Remove workarounds for seabirdscientific before 3.0.0 - #55

Merged
webbpinner merged 1 commit into
mainfrom
remove-old-seabirdscientific-workarounds
Oct 22, 2026
Merged

webbpinner merged 1 commit into
mainfrom
remove-old-seabirdscientific-workarounds

Conversation

@webbpinner

Copy link
Copy Markdown
Contributor

Follow-up to #54. Now that the dependency is seabirdscientific >= 3.0.0, the workarounds for older versions can't run anymore.

Changes

  • status.py: remove status_fields_reversed() and the reversed field order (fork issue 24). reconstruct_nibble() reads the four status fields in 3.0.0's order. probe_scan moves into tests/test_status.py, where test_recovers_raw_nibble_from_installed_seabirdscientific still checks all 16 nibbles against the installed seabirdscientific, so a change in the bit order would fail CI. The test that faked the old mapping is removed.
  • plots.py: remove the fallback for a one-column contour grid ("density grid too narrow to contour"; fork issue 21). 3.0.0 pads the salinity grid by ±1.0 in 0.1 steps, so the grid always has at least 11 columns. I checked single-sample and near-freshwater inputs, which gave 12-column grids. The existing guard for casts with no salinity above TS_MIN_SALINITY stays, since seabirdscientific raises an error when there are no samples.
  • README ("seabirdscientific version") and CLAUDE.md: no longer describe the workarounds.

Verification

  • uv run pytest: 292 passed. That's 2 fewer than before because the reversed-mapping test was removed. The R2R filesets were present, so the parity tests ran.
  • ruff check and ruff format --check pass.
  • I ran run on SP2613, RR2605 and BH18-18: all 33 SVGs are byte-identical to the output before this change.

🤖 Generated with Claude Code

The dependency is now seabirdscientific >= 3.0.0, which has the
911plus status-bit fix
(webbpinner/seabirdscientific#24) and the
contour-grid fix
(webbpinner/seabirdscientific#21), so the
workarounds for earlier versions can't run:

- status.py: drop status_fields_reversed() and read the status fields
  in the fixed order. The probe scan moves to tests/test_status.py,
  which still checks the installed version decodes every nibble.
- plots.py: drop the one-column contour grid fallback. 3.0.0 pads the
  salinity grid by 1.0 in 0.1 steps, so it always has 11+ columns.

The three validation filesets' SVGs are unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@webbpinner
webbpinner merged commit a64ec2a into main Oct 22, 2026
9 checks passed
@webbpinner
webbpinner deleted the remove-old-seabirdscientific-workarounds branch October 24, 2026 08:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant