Skip to content

[CLEANUP] Repo hygiene: pyproject-only dependencies, ctdcast-shaped CI, docs without conda - #38

Merged
eleanorfrajka merged 12 commits into
mainfrom
cleanup/repo-hygiene
Sep 8, 2026
Merged

eleanorfrajka merged 12 commits into
mainfrom
cleanup/repo-hygiene

Conversation

@eleanorfrajka

Copy link
Copy Markdown
Collaborator

Summary

Bring caldip's packaging and CI in line with the sibling repos (ctdcast, oceanarray). Dependencies move into pyproject.toml, the three requirements*.txt files are removed, the test workflow adopts the ctdcast matrix shape with a coverage floor, and the docs workflows drop conda for setup-python + pandoc. No output, attribute, variable-name or public-call changes — this is housekeeping only.

What's changed

  • Dependencies are declared inline in pyproject.toml: [project.dependencies] (the former requirements.txt) plus [project.optional-dependencies] with test, docs and dev extras. dynamic = ["dependencies"] and [tool.setuptools.dynamic] are removed; the version stays hard-coded.
  • requirements.txt, requirements-dev.txt and requirements-test.txt are deleted. Development install is now pip install -e ".[dev]"; README, installation, quickstart and FAQ prose are updated to match.
  • requires-python is now >=3.10,<3.14 (3.9 was never tested in CI; the cap matches the tested range); classifiers list 3.10–3.13.
  • Ruff is configured ([tool.ruff]) with the ctdcast select list and the numpy docstring convention, and replaces black ([tool.black] removed). The config landed first as the work list, then the safe ruff --fix + ruff format pass (204 auto-fixes). The remaining annotation/docstring/blind-except violations are a tracked burndown, not silenced (see Tests).
  • tests.yml adopts the ctdcast/oceanarray shape: fail-fast: false, Ubuntu on Python 3.10–3.12 with 3.13 as an allow-failure cell (continue-on-error), macOS and Windows on 3.12, pip install -e ".[test]", and --cov=caldip --cov-fail-under=52 on the Ubuntu 3.12 cell (every other cell --no-cov). The leftover echo step, the bash -l {0} default and the requirements*.txt path trigger are gone; .github/workflows/** is added to the triggers.
  • docs.yml and docs_deploy.yml drop micromamba for actions/setup-python (3.12) + apt-get install pandoc + pip install -e ".[docs]", keeping fetch-depth: 0 and the commented-out notebook execution.
  • The tracked example script msm142_calc_offset_example.py moves from the repo root into scripts/.
  • README gains a PyPI badge; the Python badge reads 3.10+.
  • CHANGELOG: the [0.1.0] entry no longer lists caldip report (it landed in [FEAT] Add caldip report for per-cruise HTML calibration reports #33 / 0.2.0); an [Unreleased] entry records the dependency, ruff, CI and requires-python changes.

Breaking changes

  • requires-python is raised to >=3.10. A Python 3.9 user can no longer install caldip; this is listed because the CHANGELOG rule requires it, and does not by itself make the next release a minor.

Tests

The suite is unchanged and passes: 188 pass with the 4 seabirdscientific integration tests deselected (they run and pass in CI, which installs seabird); coverage on that set is 53.28%, above the 52% floor.

The ruff burndown is complete — ruff check . and ruff format --check . are both clean, with no new ignore entries. Type annotations and numpy-style docstrings were added across the CLI, readers, writers and plotting modules; every blind except Exception was triaged (narrowed to a specific type where clear, otherwise a per-line # noqa: BLE001 with a stated reason at a genuine I/O boundary); and the grandfathered np.random calls in the synthetic tests moved to np.random.default_rng. No runtime behaviour, output or public call changed.

Notes

Ships as v0.2.1 — chosen so the corrected install instructions reach the PyPI project page (the 0.2.0 upload still shows the old README). The coverage floor is provisional at 52 and should be raised once the first CI run reports the real number. The vendored design-system files (report/_css.py, config/report_tokens.py) have already forked across the sibling repos despite comments claiming byte-identity — an argument for the planned cross-repo hash check.

Copilot AI and others added 2 commits September 8, 2026 14:59
Co-authored-by: eleanorfrajka <12586657+eleanorfrajka@users.noreply.github.com>
Co-authored-by: eleanorfrajka <12586657+eleanorfrajka@users.noreply.github.com>
@eleanorfrajka
eleanorfrajka merged commit 8d915da into main Sep 8, 2026
7 checks passed
@eleanorfrajka
eleanorfrajka deleted the cleanup/repo-hygiene branch September 8, 2026 15:21
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.

2 participants