Skip to content

Fix release-readiness findings and release 1.6.3#15

Merged
wlaur merged 1 commit into
mainfrom
fix/release-readiness-1.6.3
Jul 8, 2026
Merged

Fix release-readiness findings and release 1.6.3#15
wlaur merged 1 commit into
mainfrom
fix/release-readiness-1.6.3

Conversation

@wlaur

@wlaur wlaur commented Jul 8, 2026

Copy link
Copy Markdown
Owner

Works through the findings in REVIEW.md in order of severity, then bumps the patch version to 1.6.3.

CRITICAL

  • ReadTheDocs build fixed. nbsphinx executed the example notebooks in a separate Jupyter kernel that gets neither conf.py's sys.path insert nor an installed encomp (RTD uses --no-install-project), so every RTD build broke from PR Address release readiness review #13 onward and the 1.6.2 docs never published. Render committed notebook outputs on RTD (nbsphinx_execute="never" when READTHEDOCS is set); CI's sphinx-build -W (real plugin, executes notebooks) stays the correctness gate. Stale .readthedocs.yaml comment updated.

MAJOR

  • docs/usage.md media-dimensionalities claim corrected. Only normal and currency are predefined; media dims (dry_air/fuel) are user-defined via define_dimensionality(), and water is a pint density unit that can't be used as a media tag.

MINOR

  • docs-rtd CI job rebuilds the docs in an RTD-equivalent environment (no project install, READTHEDOCS set); publish now depends on it, so an RTD-only break fails the PR instead of silently landing.
  • FrequencyUnits literal + __new__ overloads: Q(50, "Hz") now infers Frequency statically and Hz is in get_registered_units().
  • README: documented the stray-.env import-failure footgun.
  • Test-debt cleanup in test_units.py: assert the current redirect behavior instead of a disabled negative test; narrow broad pytest.raises(Exception) to DimensionalityTypeError.

NIT

  • Reworded the "base class cannot be instantiated" note; @lru_cache on lib_version(); deleted the redundant Water.REPR_PROPERTIES; README changelog pointer (GitHub Releases) + in-wheel test-suite note.

Tests

  • Meaningful public-API tests for previously-uncovered behavior (isinstance_types non-Quantity unions, convert_volume_mass Series-density validation, convert_gas_volume invalid condition, Dimensionality subclass errors, coolprop invalid assume_phase, Quantity.check() with a Dimensionality instance / raw pint quantity, Fluid/Water/HumidAir fixed-point-count validation, describe() unknown name, Frequency inference). conversion/gases/misc reach 100%.

Local verification

  • pyright (strict): 0 errors. pyrefly check: 0 errors (42 suppressed). ruff check/format: clean.
  • pytest: 694 passed.
  • Docs build clean with -W both ways: RTD path (READTHEDOCS=True, notebooks not executed) and CI path (notebooks executed with the real plugin).

🤖 Generated with Claude Code

Addresses the holistic review in REVIEW.md, in order of severity.

CRITICAL
- Fix the ReadTheDocs build: nbsphinx executed the example notebooks in a
  separate Jupyter kernel that has neither conf.py's sys.path insert nor an
  installed encomp (RTD uses --no-install-project), so every RTD build broke
  from PR #13 and the 1.6.2 docs never published. Render committed notebook
  outputs on RTD (nbsphinx_execute="never" when READTHEDOCS is set) and keep
  CI's sphinx-build -W as the notebook-correctness gate. Update the stale
  .readthedocs.yaml comment.

MAJOR
- Reword docs/usage.md "Custom base dimensionalities": only `normal` and
  `currency` are predefined; media dims (dry_air/fuel) are user-defined, and
  `water` is a pint density unit that cannot be used as a media tag.

MINOR
- Add a docs-rtd CI job that rebuilds the docs in an RTD-equivalent
  environment (no project install, READTHEDOCS set) and gate publish on it,
  so an RTD-only break fails the PR instead of silently landing.
- Add FrequencyUnits literal + __new__ overloads so Q(50, "Hz") infers
  Frequency statically and Hz is in get_registered_units().
- Document the stray-.env import-failure footgun in the README Settings section.
- Clean up test-debt markers in test_units.py: assert the current redirect
  behavior instead of a disabled negative test, and narrow broad
  pytest.raises(Exception) catches to DimensionalityTypeError.

NIT
- Reword the "base class cannot be instantiated" usage note.
- Cache lib_version() with lru_cache like its siblings.
- Delete the redundant Water.REPR_PROPERTIES (inherited unchanged).
- Add README changelog pointer (GitHub Releases) and document the in-wheel
  test suite as a post-install smoke test.

Tests
- Add meaningful public-API tests for previously-uncovered behavior:
  isinstance_types non-Quantity unions, convert_volume_mass Series-density
  validation, convert_gas_volume invalid-condition typing, Dimensionality
  subclass errors, coolprop invalid assume_phase, Quantity.check() with a
  Dimensionality instance / raw pint quantity, Fluid/Water/HumidAir
  fixed-point-count validation, describe() unknown name, and Frequency
  inference. conversion/gases/misc reach 100%.

Bump version to 1.6.3 (pyproject, uv.lock, README logo tag).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@wlaur wlaur merged commit ee09814 into main Jul 8, 2026
17 checks passed
@wlaur wlaur deleted the fix/release-readiness-1.6.3 branch July 8, 2026 15:32
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