Skip to content

Drop internal docs/units.md references from user-facing text - #738

Open
amarcozzi wants to merge 1 commit into
mainfrom
737-drop-units-md-refs
Open

amarcozzi wants to merge 1 commit into
mainfrom
737-drop-units-md-refs

Conversation

@amarcozzi

Copy link
Copy Markdown
Contributor

Closes #737

User-facing text pointed readers to docs/units.md, which is internal and not published. This drops the sentence everywhere it reached users. The rule itself (UDUNITS-2-conformant ASCII with ** exponents) is still stated in each place.

Changes

  • grids/schema.py: Band.unit description
  • grids/upload/geotiff/schema.py: UploadBandDefinition.unit description
  • grids/upload/netcdf/router.py: endpoint docstring
  • lib/units.py: the validate_unit error message, which reaches users as a 422 detail for a non-canonical unit. It now reads Unit 'kg/m^3' is not canonical; expected 'kg/m**3'.

The internal module docstring in lib/units.py keeps its reference.

Ripples

  • The SDK's generated client copies these descriptions, so its next regen picks up the change. No code change is needed.
  • No contract change: only description text and one error-message string.

Verification

  • pytest tests/resources/grids/test_schema.py tests/resources/grids/upload (schema tests): 121 passed
  • services/lib: pytest tests/test_units.py: 41 passed
  • import api.main works

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.

OpenAPI: drop references to internal docs/units.md

1 participant