Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

regionate

A package for creating xgcm-grid consistent regional masks and boundaries, leveraging its sibling package sectionate.

PyPI Conda Version Docs License

Quick Start Guide

For users: minimal installation within an existing environment

conda install -c conda-forge regionate

For developers: installing from scratch using conda

git clone git@github.com:hdrake/regionate.git
cd regionate
conda env create -f docs/environment.yml
conda activate docs_env_regionate
pip install -e .
python -m ipykernel install --user --name docs_env_regionate --display-name "docs_env_regionate"
jupyter-lab

Releasing

The git tag is the version. regionate has no version string checked into the source tree: hatch-vcs derives it from the tag at build time and writes regionate/_version.py (gitignored, but shipped inside the sdist and wheel). To cut a release you tag; there is no file to bump and nothing to keep in sync.

  1. Make sure main is green and has everything you want in the release.
  2. Publish a GitHub Release whose tag is vX.Y.Z, targeting the commit you want to ship:
    gh release create vX.Y.Z --target "$(git rev-parse origin/main)" \
      --title vX.Y.Z --generate-notes
    
    Publishing it (not merely pushing a tag) is what fires the workflow. Target the commit you actually want: a tag placed before the commit you meant to release builds the previous version, and PyPI rejects it as a duplicate.
  3. The Publish to PyPI workflow builds from that tag and uploads. It checks out with fetch-depth: 0 so the tag is visible to hatch-vcs, and asserts that the built version matches the tag before publishing.
  4. Verify: https://pypi.org/project/regionate/.
  5. conda-forge builds from the PyPI sdist and lags by design; the autotick bot opens the version-bump PR. Its recipe must list hatch-vcs alongside hatchling in host, since it builds with --no-build-isolation.

Two things follow from the tag being the version. Never add a version literal back to the tree — regionate/version.py is a shim over the generated file, and a 0.0.0+unknown from it means the package was imported without being built or installed, not that a number is missing. And any checkout that installs the package needs its tags: a shallow clone, or a fork that never fetched them, resolves a .devN version instead of the release line. That is why CI checks out with fetch-depth: 0 and Read the Docs unshallows in post_checkout.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

regionate-0.6.0rc1.tar.gz (71.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

regionate-0.6.0rc1-py3-none-any.whl (69.9 kB view details)

Uploaded Python 3

File details

Details for the file regionate-0.6.0rc1.tar.gz.

File metadata

  • Download URL: regionate-0.6.0rc1.tar.gz
  • Upload date:
  • Size: 71.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.14.6

File hashes

Hashes for regionate-0.6.0rc1.tar.gz
Algorithm Hash digest
SHA256 74e0ab69374535d0892b6437397536ef04977e54efe9e27b765aa4b277506168
MD5 da08dc8bae4caf718444e33cedbb3007
BLAKE2b-256 198345c03b6b6986d8d86711f7a62c57ab4e51de379bd830dac3bd4199455292

See more details on using hashes here.

File details

Details for the file regionate-0.6.0rc1-py3-none-any.whl.

File metadata

  • Download URL: regionate-0.6.0rc1-py3-none-any.whl
  • Upload date:
  • Size: 69.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.14.6

File hashes

Hashes for regionate-0.6.0rc1-py3-none-any.whl
Algorithm Hash digest
SHA256 b58d693361da6d5e6fc8e09c3946f561934a82617ee47c2ecdd40cde2856f083
MD5 f3e0e9244cdcf30a0e1d49f79b7c0b02
BLAKE2b-256 f0054c4e9f0e9f7ff8e61e53f9f812809d4ea527fbdd848e92607cd17f3a5b23

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page