From b439dce6953fec8ee97ef44bb6610edb2f011eef Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Mon, 28 Apr 2025 12:46:20 -0600 Subject: [PATCH 01/51] GitHub Actions workflow updates (#267) * Update ci.yml * Update pypi.yaml --- .github/workflows/ci.yml | 35 +++++++++++------------------------ .github/workflows/pypi.yaml | 18 ++++++++---------- 2 files changed, 19 insertions(+), 34 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6d41fe7..aca255d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -9,54 +9,41 @@ on: schedule: - cron: '0 0 * * *' # Daily “At 00:00” +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + jobs: test: - name: Python (${{ matrix.python-version }}, ${{ matrix.os }}) + name: Python ${{ matrix.python-version }}, ${{ matrix.os }} runs-on: ${{ matrix.os }} defaults: run: shell: bash -l {0} - strategy: fail-fast: false matrix: os: [ "ubuntu-latest", "macos-latest", "macos-14" ] python-version: [ "3.9", "3.10", "3.11", "3.12" ] - steps: - - name: Cancel previous runs - uses: styfle/cancel-workflow-action@0.12.1 - with: - access_token: ${{ github.token }} - - name: Checkout + - name: checkout uses: actions/checkout@v4 + - name: environment setup + uses: conda-incubator/setup-miniconda@505e6394dae86d6a5c7fbb6e3fb8938e3e863830 # v3.1.1 with: - token: ${{ github.token }} - - name: Conda setup - uses: conda-incubator/setup-miniconda@v3 - if: matrix.os != 'macos-14' - with: - python-version: ${{ matrix.python-version }} - channels: conda-forge - environment-file: build_envs/environment.yml - - name: Conda setup (macOS M1) - uses: conda-incubator/setup-miniconda@v3 - if: matrix.os == 'macos-14' - with: - installer-url: https://github.com/conda-forge/miniforge/releases/download/23.11.0-0/Mambaforge-23.11.0-0-MacOSX-arm64.sh python-version: ${{ matrix.python-version }} channels: conda-forge environment-file: build_envs/environment.yml - - name: Build WRF-Python + - name: build WRF-Python run: | python -m pip install build python -m build . python -m pip install dist/wrf*.whl - - name: Run tests + - name: run tests run: | cd test/ci_tests python utests.py - - name: Check import + - name: check import if: failure() run: | python -m pip show wrf-python diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml index 9919c74..b79509f 100644 --- a/.github/workflows/pypi.yaml +++ b/.github/workflows/pypi.yaml @@ -12,15 +12,14 @@ jobs: - name: Set up Python uses: actions/setup-python@v5 with: - python-version: '3.x' + python-version: '3.10' - name: Install dependencies run: | python -m pip install --upgrade pip - python -m pip install setuptools setuptools-scm wheel twine check-manifest + python -m pip install build twine - name: Build tarball and wheels run: | - python setup.py sdist bdist_wheel - python -m pip wheel . -w dist --no-deps + python -m build - name: Test the artifacts run: | python -m twine check dist/* @@ -33,22 +32,21 @@ jobs: - name: Set up Python uses: actions/setup-python@v5 with: - python-version: '3.x' + python-version: '3.10' - name: Install dependencies run: | python -m pip install --upgrade pip - python -m pip install setuptools setuptools-scm wheel twine check-manifest + python -m pip install build twine - name: Build tarball and wheels run: | - python setup.py sdist bdist_wheel - python -m pip wheel . -w dist --no-deps + python -m build - name: Test the artifacts run: | python -m twine check dist/* - name: Publish package to PyPI - uses: pypa/gh-action-pypi-publish@v1.12.4 + uses: pypa/gh-action-pypi-publish@76f52bc884231f62b9a034ebfe128415bbaabdfc # v1.12.4 with: user: __token__ password: ${{ secrets.PYPI_WRF_PYTHON }} skip_existing: true - verbose: true \ No newline at end of file + verbose: true From d48203b4ca41eb61544c9e456fa1bff7607f721b Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Thu, 15 May 2025 13:06:14 -0600 Subject: [PATCH 02/51] v1.4.0 - release notes and version update (#269) * update release notes * update version number --- doc/source/new.rst | 9 +++++++++ src/wrf/version.py | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/doc/source/new.rst b/doc/source/new.rst index 6e8719d..364af0b 100644 --- a/doc/source/new.rst +++ b/doc/source/new.rst @@ -4,6 +4,15 @@ What's New Releases ------------- +v1.4.0 (May 2025) +^^^^^^^^^^^^^^^^^^^^^^^^^ + +- Release 1.4.0 +- Transition to CMake build using scikit-build-core +- Packaging updates and adoption of pyproject.toml +- Support for Python 3.12 +- Support for macOS ARM architecture + v1.3.2 (February 2019) ^^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/src/wrf/version.py b/src/wrf/version.py index b7b278a..3e8d9f9 100644 --- a/src/wrf/version.py +++ b/src/wrf/version.py @@ -1 +1 @@ -__version__ = "1.3.4.1" +__version__ = "1.4.0" From 7643b9b3073608134590ff3f93cf0d5990fba293 Mon Sep 17 00:00:00 2001 From: "Keith F. Prussing" Date: Thu, 6 Mar 2025 14:55:47 -0500 Subject: [PATCH 03/51] Remove np.float_ as a fill option Running with NumPy 2.2.2 produces the following error: AttributeError: `np.float_` was removed in the NumPy 2.0 release. Use `np.float64` instead. This removes the unsupported type. --- src/wrf/constants.py | 1 - 1 file changed, 1 deletion(-) diff --git a/src/wrf/constants.py b/src/wrf/constants.py index d660c62..1d400af 100644 --- a/src/wrf/constants.py +++ b/src/wrf/constants.py @@ -59,7 +59,6 @@ class ProjectionTypes(object): np.dtype(np.uint32): 4294967295, np.dtype(np.int64): Constants.DEFAULT_FILL_INT64, np.dtype(np.uint64): 18446744073709551614, - np.dtype(np.float_): Constants.DEFAULT_FILL_DOUBLE, np.dtype(np.float32): Constants.DEFAULT_FILL_FLOAT, np.dtype(np.float64): Constants.DEFAULT_FILL_DOUBLE } From 7f6dc9986b990782e56c9169b8ef7c1f15a71b9e Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 16 Jul 2025 15:40:04 -0600 Subject: [PATCH 04/51] adjust tolerance to allow for precision level diffs introduced by upstream changes --- test/ci_tests/utests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ci_tests/utests.py b/test/ci_tests/utests.py index 5ae40e1..133afb0 100644 --- a/test/ci_tests/utests.py +++ b/test/ci_tests/utests.py @@ -107,7 +107,7 @@ def test(self): # print (hts_850) hts_850 = interplevel(hts, p, 850) - nt.assert_allclose(to_np(hts_850), ref_ht_850) + nt.assert_allclose(to_np(hts_850), ref_ht_850, rtol=1e-06) elif (varname == "vertcross"): ref_ht_cross = _get_refvals(referent, "vertcross", repeat, multi) From f87adf8958640beaf4228bfd37a53cc4123e781f Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 16 Jul 2025 15:52:55 -0600 Subject: [PATCH 05/51] add NumPy version conditional for default fill mapping --- src/wrf/constants.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/wrf/constants.py b/src/wrf/constants.py index 1d400af..5243705 100644 --- a/src/wrf/constants.py +++ b/src/wrf/constants.py @@ -7,6 +7,9 @@ from .py3compat import viewitems from ._wrffortran import wrf_constants, omp_constants +from packaging.version import Version +np_version = Version(np.__version__) + #: Indicates that all times should be used in a diagnostic routine. ALL_TIMES = None @@ -63,6 +66,9 @@ class ProjectionTypes(object): np.dtype(np.float64): Constants.DEFAULT_FILL_DOUBLE } +if np_version < Version('2.0'): + _DEFAULT_FILL_MAP[np.float_] = Constants.Constants.DEFAULT_FILL_DOUBLE + if version_info >= (3, ): _DEFAULT_FILL_MAP[np.int_] = Constants.DEFAULT_FILL_INT64 else: From acd95e15737702fce32f6c4b4307070813f1d3c0 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 16 Jul 2025 16:04:11 -0600 Subject: [PATCH 06/51] Update environment.yml --- build_envs/environment.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/build_envs/environment.yml b/build_envs/environment.yml index 4c646a3..6a6e7c9 100644 --- a/build_envs/environment.yml +++ b/build_envs/environment.yml @@ -11,6 +11,7 @@ dependencies: - matplotlib - netcdf4 - numpy + - packaging - pycodestyle - setuptools - sphinx From a2197270c10399bd910d62cedd8877a3bdb4d805 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 16 Jul 2025 18:24:39 -0600 Subject: [PATCH 07/51] Update constants.py --- src/wrf/constants.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/wrf/constants.py b/src/wrf/constants.py index 5243705..827fed3 100644 --- a/src/wrf/constants.py +++ b/src/wrf/constants.py @@ -7,9 +7,6 @@ from .py3compat import viewitems from ._wrffortran import wrf_constants, omp_constants -from packaging.version import Version -np_version = Version(np.__version__) - #: Indicates that all times should be used in a diagnostic routine. ALL_TIMES = None @@ -66,8 +63,10 @@ class ProjectionTypes(object): np.dtype(np.float64): Constants.DEFAULT_FILL_DOUBLE } -if np_version < Version('2.0'): - _DEFAULT_FILL_MAP[np.float_] = Constants.Constants.DEFAULT_FILL_DOUBLE +try: + _DEFAULT_FILL_MAP[np.dtype(np.float_)] = Constants.DEFAULT_FILL_DOUBLE +except AttributeError: + pass if version_info >= (3, ): _DEFAULT_FILL_MAP[np.int_] = Constants.DEFAULT_FILL_INT64 From 683a5ecb321f4b58cad09ddd0f4883b6a94d5a81 Mon Sep 17 00:00:00 2001 From: Subrota Halder Date: Sat, 24 May 2025 19:55:59 +0400 Subject: [PATCH 08/51] Update subproducts.txt --- doc/source/_templates/subproducts.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/source/_templates/subproducts.txt b/doc/source/_templates/subproducts.txt index a13b2db..8a66605 100644 --- a/doc/source/_templates/subproducts.txt +++ b/doc/source/_templates/subproducts.txt @@ -5,9 +5,9 @@ +--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ | mcin | cape_2d | 2D Max CIN | J kg-1 | **missing** (float): Fill value for output only | +--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ -| lcl | cape_2d | 2D Lifted Condensation Level | J kg-1 | **missing** (float): Fill value for output only | +| lcl | cape_2d | 2D Lifted Condensation Level | m | **missing** (float): Fill value for output only | +--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ -| lfc | cape_2d | 2D Level of Free Convection | J kg-1 | **missing** (float): Fill value for output only | +| lfc | cape_2d | 2D Level of Free Convection | m | **missing** (float): Fill value for output only | +--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ | cape3d_only | cape_3d | 3D CAPE | J kg-1 | **missing** (float): Fill value for output only | +--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -116,4 +116,4 @@ | | | | kt | | | | | | | | | | | | ft s-1 | | -+--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ \ No newline at end of file ++--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ From bb3d983a8c95b946be5e608c41cb174bbdbaa3e2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 17 Jul 2025 00:53:27 +0000 Subject: [PATCH 09/51] Bump conda-incubator/setup-miniconda from 3.1.1 to 3.2.0 Bumps [conda-incubator/setup-miniconda](https://github.com/conda-incubator/setup-miniconda) from 3.1.1 to 3.2.0. - [Release notes](https://github.com/conda-incubator/setup-miniconda/releases) - [Changelog](https://github.com/conda-incubator/setup-miniconda/blob/main/CHANGELOG.md) - [Commits](https://github.com/conda-incubator/setup-miniconda/compare/505e6394dae86d6a5c7fbb6e3fb8938e3e863830...835234971496cad1653abb28a638a281cf32541f) --- updated-dependencies: - dependency-name: conda-incubator/setup-miniconda dependency-version: 3.2.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index aca255d..686e41f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,7 +29,7 @@ jobs: - name: checkout uses: actions/checkout@v4 - name: environment setup - uses: conda-incubator/setup-miniconda@505e6394dae86d6a5c7fbb6e3fb8938e3e863830 # v3.1.1 + uses: conda-incubator/setup-miniconda@835234971496cad1653abb28a638a281cf32541f # v3.2.0 with: python-version: ${{ matrix.python-version }} channels: conda-forge From 0940ff0f76c62b1433c30116d7d1a778ec6fe5ac Mon Sep 17 00:00:00 2001 From: akrherz Date: Sat, 14 Jun 2025 07:54:51 -0500 Subject: [PATCH 10/51] Add python 3.13 to CI and metadata --- .github/workflows/ci.yml | 2 +- build_envs/environment.yml | 2 +- pyproject.toml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 686e41f..c487231 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,7 +24,7 @@ jobs: fail-fast: false matrix: os: [ "ubuntu-latest", "macos-latest", "macos-14" ] - python-version: [ "3.9", "3.10", "3.11", "3.12" ] + python-version: [ "3.9", "3.10", "3.11", "3.12", "3.13" ] steps: - name: checkout uses: actions/checkout@v4 diff --git a/build_envs/environment.yml b/build_envs/environment.yml index 6a6e7c9..a540f57 100644 --- a/build_envs/environment.yml +++ b/build_envs/environment.yml @@ -3,7 +3,7 @@ name: wrf_python_build channels: - conda-forge dependencies: - - python>=3.9, <3.13 + - python>=3.9, <3.14 - compilers - basemap - cartopy diff --git a/pyproject.toml b/pyproject.toml index 5047e19..2a882c8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -12,7 +12,7 @@ maintainers = [ ] description = "Diagnostic and interpolation routines for WRF-ARW data." readme = "README.md" -requires-python = ">=3.9, <3.13" +requires-python = ">=3.9, <3.14" keywords = [ "python", "wrf-python", "wrf", "forecast", "model", "weather research and forecasting", "interpolation", From b9dbdd3e1a1661a81c1005be0d869a1d7e766385 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Thu, 17 Jul 2025 10:18:28 -0600 Subject: [PATCH 11/51] remove deprecated use of pkg_resources --- build_envs/environment.yml | 2 -- src/wrf/__init__.py | 20 ++------------------ 2 files changed, 2 insertions(+), 20 deletions(-) diff --git a/build_envs/environment.yml b/build_envs/environment.yml index a540f57..e889284 100644 --- a/build_envs/environment.yml +++ b/build_envs/environment.yml @@ -11,9 +11,7 @@ dependencies: - matplotlib - netcdf4 - numpy - - packaging - pycodestyle - - setuptools - sphinx - sphinx_rtd_theme - sphinxcontrib-googleanalytics diff --git a/src/wrf/__init__.py b/src/wrf/__init__.py index 39cd608..d848dd0 100644 --- a/src/wrf/__init__.py +++ b/src/wrf/__init__.py @@ -2,24 +2,8 @@ import os import pkg_resources -try: - from . import api - from .api import * -except ImportError: - # For gfortran+msvc combination, extra shared libraries may exist - # (stored by numpy.distutils) - if os.name == "nt": - req = pkg_resources.Requirement.parse("wrf-python") - extra_dll_dir = pkg_resources.resource_filename(req, - "wrf-python/.libs") - if os.path.isdir(extra_dll_dir): - os.environ["PATH"] += os.pathsep + extra_dll_dir - - from . import api - from .api import * - else: - raise - +from . import api +from .api import * __all__ = [] __all__.extend(api.__all__) From 4c2e3560cba2c9b21966543342bb31e884e2ed2c Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Thu, 17 Jul 2025 10:22:19 -0600 Subject: [PATCH 12/51] remove import as well --- src/wrf/__init__.py | 1 - 1 file changed, 1 deletion(-) diff --git a/src/wrf/__init__.py b/src/wrf/__init__.py index d848dd0..99334d9 100644 --- a/src/wrf/__init__.py +++ b/src/wrf/__init__.py @@ -1,6 +1,5 @@ from __future__ import (absolute_import, division, print_function) import os -import pkg_resources from . import api from .api import * From 24b40372e4facf02e18053450f35b184f88273f5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Aug 2025 05:14:23 +0000 Subject: [PATCH 13/51] Bump actions/checkout from 4 to 5 Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- .github/workflows/pypi.yaml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c487231..e16ac08 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -27,7 +27,7 @@ jobs: python-version: [ "3.9", "3.10", "3.11", "3.12", "3.13" ] steps: - name: checkout - uses: actions/checkout@v4 + uses: actions/checkout@v5 - name: environment setup uses: conda-incubator/setup-miniconda@835234971496cad1653abb28a638a281cf32541f # v3.2.0 with: diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml index b79509f..ef01061 100644 --- a/.github/workflows/pypi.yaml +++ b/.github/workflows/pypi.yaml @@ -8,7 +8,7 @@ jobs: if: github.repository == 'NCAR/wrf-python' runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Set up Python uses: actions/setup-python@v5 with: @@ -28,7 +28,7 @@ jobs: if: startsWith(github.ref, 'refs/tags') runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Set up Python uses: actions/setup-python@v5 with: From c4563d324d409a1d1e91ed16a8454b55698e6ae5 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Fri, 22 Aug 2025 12:56:05 -0600 Subject: [PATCH 14/51] Update docs to show lat lon labels and remove outdated note --- doc/source/plot.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/source/plot.rst b/doc/source/plot.rst index fb69a7f..19b7392 100644 --- a/doc/source/plot.rst +++ b/doc/source/plot.rst @@ -23,9 +23,6 @@ should be aware of a few shortcomings when working with WRF data. - The rotated pole projection requires the x and y limits to be set manually using set_xlim and set_ylim. -- You can't place latitude and longitude labels on the axes when using - any projection other than Mercator or LatLon. - Plotting a Two-dimensional Field ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -89,7 +86,10 @@ Plotting a Two-dimensional Field ax.set_ylim(cartopy_ylim(smooth_slp)) # Add the gridlines - ax.gridlines(color="black", linestyle="dotted") + gl = ax.gridlines(draw_labels=True, color="black", linestyle="dotted") + gl.right_labels = False + gl.x_inline = False + gl.top_labels = False plt.title("Sea Level Pressure (hPa)") From 5d7ad252b56dee8d32804de6d826fec029fd40d3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Sep 2025 21:01:59 +0000 Subject: [PATCH 15/51] Bump actions/setup-python from 5 to 6 Bumps [actions/setup-python](https://github.com/actions/setup-python) from 5 to 6. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](https://github.com/actions/setup-python/compare/v5...v6) --- updated-dependencies: - dependency-name: actions/setup-python dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/pypi.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml index ef01061..2089a56 100644 --- a/.github/workflows/pypi.yaml +++ b/.github/workflows/pypi.yaml @@ -10,7 +10,7 @@ jobs: steps: - uses: actions/checkout@v5 - name: Set up Python - uses: actions/setup-python@v5 + uses: actions/setup-python@v6 with: python-version: '3.10' - name: Install dependencies @@ -30,7 +30,7 @@ jobs: steps: - uses: actions/checkout@v5 - name: Set up Python - uses: actions/setup-python@v5 + uses: actions/setup-python@v6 with: python-version: '3.10' - name: Install dependencies From 9313e05d27297b0be9cf5ccbd31be4f63851ff24 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Sep 2025 21:01:09 +0000 Subject: [PATCH 16/51] Bump pypa/gh-action-pypi-publish from 1.12.4 to 1.13.0 Bumps [pypa/gh-action-pypi-publish](https://github.com/pypa/gh-action-pypi-publish) from 1.12.4 to 1.13.0. - [Release notes](https://github.com/pypa/gh-action-pypi-publish/releases) - [Commits](https://github.com/pypa/gh-action-pypi-publish/compare/76f52bc884231f62b9a034ebfe128415bbaabdfc...ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e) --- updated-dependencies: - dependency-name: pypa/gh-action-pypi-publish dependency-version: 1.13.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/pypi.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml index 2089a56..cc57f0b 100644 --- a/.github/workflows/pypi.yaml +++ b/.github/workflows/pypi.yaml @@ -44,7 +44,7 @@ jobs: run: | python -m twine check dist/* - name: Publish package to PyPI - uses: pypa/gh-action-pypi-publish@76f52bc884231f62b9a034ebfe128415bbaabdfc # v1.12.4 + uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0 with: user: __token__ password: ${{ secrets.PYPI_WRF_PYTHON }} From 3616f0f27a656e18588ed204c8cb6f4764e933c8 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Tue, 21 Oct 2025 14:44:13 -0700 Subject: [PATCH 17/51] fix for netCDF4 v1.7.3 iterator changes --- src/wrf/util.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/wrf/util.py b/src/wrf/util.py index 40229c7..03cb7a1 100644 --- a/src/wrf/util.py +++ b/src/wrf/util.py @@ -134,7 +134,13 @@ def is_multi_file(wrfin): is a single NetCDF file object. """ - return (isinstance(wrfin, Iterable) and not isstr(wrfin)) + try: + iter(wrfin) + is_iterable = True + except Exception: + is_iterable = False + + return (is_iterable and not isstr(wrfin)) def has_time_coord(wrfnc): From 72017e526068b75d5a009ded04c535c576faf118 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 22 Oct 2025 07:01:35 -0700 Subject: [PATCH 18/51] oops update the check to work for the older version of netcdf4 --- src/wrf/util.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/wrf/util.py b/src/wrf/util.py index 03cb7a1..99ef9ae 100644 --- a/src/wrf/util.py +++ b/src/wrf/util.py @@ -9,6 +9,7 @@ from types import GeneratorType import datetime as dt from inspect import getmodule +from netCDF4 import Dataset try: from inspect import signature @@ -134,10 +135,11 @@ def is_multi_file(wrfin): is a single NetCDF file object. """ - try: - iter(wrfin) + if isinstance(wrfin, Dataset): + is_iterable = False + elif isinstance(wrfin, Iterable): is_iterable = True - except Exception: + else: is_iterable = False return (is_iterable and not isstr(wrfin)) From 6542224d6eecb64c12badfde1c19d1dfbe759658 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Fri, 31 Oct 2025 14:47:13 -0600 Subject: [PATCH 19/51] Update Python version metadata to reflect support for 3.13 (#292) * update Python version info in pyproject.toml * remove Python version pin in macos-arm env * remove Python version pin * remove version pin for python --- build_envs/platform-specific/macos_arm64.yml | 2 +- build_envs/platform-specific/macos_x64.yml | 2 +- build_envs/platform-specific/windows.yml | 2 +- pyproject.toml | 1 + 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/build_envs/platform-specific/macos_arm64.yml b/build_envs/platform-specific/macos_arm64.yml index 2e475f0..d6483dd 100644 --- a/build_envs/platform-specific/macos_arm64.yml +++ b/build_envs/platform-specific/macos_arm64.yml @@ -3,7 +3,7 @@ name: wrf_python_build channels: - conda-forge dependencies: - - python<3.12 + - python - basemap - cartopy - clang_osx-arm64 diff --git a/build_envs/platform-specific/macos_x64.yml b/build_envs/platform-specific/macos_x64.yml index 2415ebe..ba798c2 100644 --- a/build_envs/platform-specific/macos_x64.yml +++ b/build_envs/platform-specific/macos_x64.yml @@ -3,7 +3,7 @@ name: wrf_python_build channels: - conda-forge dependencies: - - python<3.12 + - python - basemap - cartopy - clang_osx-64 diff --git a/build_envs/platform-specific/windows.yml b/build_envs/platform-specific/windows.yml index 1053db0..46d53b2 100644 --- a/build_envs/platform-specific/windows.yml +++ b/build_envs/platform-specific/windows.yml @@ -4,7 +4,7 @@ channels: - conda-forge - msys2 dependencies: - - python<3.12 + - python - basemap - cartopy - jupyter diff --git a/pyproject.toml b/pyproject.toml index 2a882c8..0f00bb5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -30,6 +30,7 @@ classifiers = [ "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", + "Programming Language :: Python :: 3.13", "Topic :: Scientific/Engineering :: Atmospheric Science", "Topic :: Software Development", "Operating System :: POSIX", From 30b2e49468d33f49c2682335d2a6e101f5c97fcb Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 5 Nov 2025 13:49:16 -0700 Subject: [PATCH 20/51] Release notes and version bump for v1.4.1 (#293) * Add release notes for version 1.4.1 * Bump version to 1.4.1 --- doc/source/new.rst | 9 +++++++++ src/wrf/version.py | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/doc/source/new.rst b/doc/source/new.rst index 364af0b..1035cae 100644 --- a/doc/source/new.rst +++ b/doc/source/new.rst @@ -4,6 +4,15 @@ What's New Releases ------------- +v1.4.1 (November 2025) +^^^^^^^^^^^^^^^^^^^^^^^^^ + +- Release 1.4.1 +- Support for Python 3.13 +- Fix to accommodate recent netCDF4 changes +- Remove pkg_resources +- Correct units for LCL and LFC in the subproduct diagnostics documentation + v1.4.0 (May 2025) ^^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/src/wrf/version.py b/src/wrf/version.py index 3e8d9f9..bf25615 100644 --- a/src/wrf/version.py +++ b/src/wrf/version.py @@ -1 +1 @@ -__version__ = "1.4.0" +__version__ = "1.4.1" From e2f04560cf36bf861a27145ed3cc3fb3a06d3b67 Mon Sep 17 00:00:00 2001 From: "Keith F. Prussing" Date: Thu, 6 Mar 2025 14:55:47 -0500 Subject: [PATCH 21/51] Remove np.float_ as a fill option Running with NumPy 2.2.2 produces the following error: AttributeError: `np.float_` was removed in the NumPy 2.0 release. Use `np.float64` instead. This removes the unsupported type. --- src/wrf/constants.py | 1 - 1 file changed, 1 deletion(-) diff --git a/src/wrf/constants.py b/src/wrf/constants.py index d660c62..1d400af 100644 --- a/src/wrf/constants.py +++ b/src/wrf/constants.py @@ -59,7 +59,6 @@ class ProjectionTypes(object): np.dtype(np.uint32): 4294967295, np.dtype(np.int64): Constants.DEFAULT_FILL_INT64, np.dtype(np.uint64): 18446744073709551614, - np.dtype(np.float_): Constants.DEFAULT_FILL_DOUBLE, np.dtype(np.float32): Constants.DEFAULT_FILL_FLOAT, np.dtype(np.float64): Constants.DEFAULT_FILL_DOUBLE } From 8a4f69fde3c45112cb27d1bec8cc7ba288e7827a Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 16 Jul 2025 15:40:04 -0600 Subject: [PATCH 22/51] adjust tolerance to allow for precision level diffs introduced by upstream changes --- test/ci_tests/utests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/ci_tests/utests.py b/test/ci_tests/utests.py index 5ae40e1..133afb0 100644 --- a/test/ci_tests/utests.py +++ b/test/ci_tests/utests.py @@ -107,7 +107,7 @@ def test(self): # print (hts_850) hts_850 = interplevel(hts, p, 850) - nt.assert_allclose(to_np(hts_850), ref_ht_850) + nt.assert_allclose(to_np(hts_850), ref_ht_850, rtol=1e-06) elif (varname == "vertcross"): ref_ht_cross = _get_refvals(referent, "vertcross", repeat, multi) From 97982efd20c4a17735c11a943c1e8b0ba1aa8852 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 16 Jul 2025 15:52:55 -0600 Subject: [PATCH 23/51] add NumPy version conditional for default fill mapping --- src/wrf/constants.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/wrf/constants.py b/src/wrf/constants.py index 1d400af..5243705 100644 --- a/src/wrf/constants.py +++ b/src/wrf/constants.py @@ -7,6 +7,9 @@ from .py3compat import viewitems from ._wrffortran import wrf_constants, omp_constants +from packaging.version import Version +np_version = Version(np.__version__) + #: Indicates that all times should be used in a diagnostic routine. ALL_TIMES = None @@ -63,6 +66,9 @@ class ProjectionTypes(object): np.dtype(np.float64): Constants.DEFAULT_FILL_DOUBLE } +if np_version < Version('2.0'): + _DEFAULT_FILL_MAP[np.float_] = Constants.Constants.DEFAULT_FILL_DOUBLE + if version_info >= (3, ): _DEFAULT_FILL_MAP[np.int_] = Constants.DEFAULT_FILL_INT64 else: From 993946ffbb7b6e9dd8f5d1768f458836b21b7368 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 16 Jul 2025 16:04:11 -0600 Subject: [PATCH 24/51] Update environment.yml --- build_envs/environment.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/build_envs/environment.yml b/build_envs/environment.yml index 4c646a3..6a6e7c9 100644 --- a/build_envs/environment.yml +++ b/build_envs/environment.yml @@ -11,6 +11,7 @@ dependencies: - matplotlib - netcdf4 - numpy + - packaging - pycodestyle - setuptools - sphinx From 907381bd93e70d7b8d8190230972b6095451ea7a Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 16 Jul 2025 18:24:39 -0600 Subject: [PATCH 25/51] Update constants.py --- src/wrf/constants.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/wrf/constants.py b/src/wrf/constants.py index 5243705..827fed3 100644 --- a/src/wrf/constants.py +++ b/src/wrf/constants.py @@ -7,9 +7,6 @@ from .py3compat import viewitems from ._wrffortran import wrf_constants, omp_constants -from packaging.version import Version -np_version = Version(np.__version__) - #: Indicates that all times should be used in a diagnostic routine. ALL_TIMES = None @@ -66,8 +63,10 @@ class ProjectionTypes(object): np.dtype(np.float64): Constants.DEFAULT_FILL_DOUBLE } -if np_version < Version('2.0'): - _DEFAULT_FILL_MAP[np.float_] = Constants.Constants.DEFAULT_FILL_DOUBLE +try: + _DEFAULT_FILL_MAP[np.dtype(np.float_)] = Constants.DEFAULT_FILL_DOUBLE +except AttributeError: + pass if version_info >= (3, ): _DEFAULT_FILL_MAP[np.int_] = Constants.DEFAULT_FILL_INT64 From 30e98dce74528e37da6bffef2b832dd813c5f12f Mon Sep 17 00:00:00 2001 From: Subrota Halder Date: Sat, 24 May 2025 19:55:59 +0400 Subject: [PATCH 26/51] Update subproducts.txt --- doc/source/_templates/subproducts.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/doc/source/_templates/subproducts.txt b/doc/source/_templates/subproducts.txt index a13b2db..8a66605 100644 --- a/doc/source/_templates/subproducts.txt +++ b/doc/source/_templates/subproducts.txt @@ -5,9 +5,9 @@ +--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ | mcin | cape_2d | 2D Max CIN | J kg-1 | **missing** (float): Fill value for output only | +--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ -| lcl | cape_2d | 2D Lifted Condensation Level | J kg-1 | **missing** (float): Fill value for output only | +| lcl | cape_2d | 2D Lifted Condensation Level | m | **missing** (float): Fill value for output only | +--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ -| lfc | cape_2d | 2D Level of Free Convection | J kg-1 | **missing** (float): Fill value for output only | +| lfc | cape_2d | 2D Level of Free Convection | m | **missing** (float): Fill value for output only | +--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ | cape3d_only | cape_3d | 3D CAPE | J kg-1 | **missing** (float): Fill value for output only | +--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -116,4 +116,4 @@ | | | | kt | | | | | | | | | | | | ft s-1 | | -+--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ \ No newline at end of file ++--------------------+----------------------+---------------------------------------------------------------+-----------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------+ From 1c16f38d8b4a79af9345d7e341008fb557488c77 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 17 Jul 2025 00:53:27 +0000 Subject: [PATCH 27/51] Bump conda-incubator/setup-miniconda from 3.1.1 to 3.2.0 Bumps [conda-incubator/setup-miniconda](https://github.com/conda-incubator/setup-miniconda) from 3.1.1 to 3.2.0. - [Release notes](https://github.com/conda-incubator/setup-miniconda/releases) - [Changelog](https://github.com/conda-incubator/setup-miniconda/blob/main/CHANGELOG.md) - [Commits](https://github.com/conda-incubator/setup-miniconda/compare/505e6394dae86d6a5c7fbb6e3fb8938e3e863830...835234971496cad1653abb28a638a281cf32541f) --- updated-dependencies: - dependency-name: conda-incubator/setup-miniconda dependency-version: 3.2.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index aca255d..686e41f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,7 +29,7 @@ jobs: - name: checkout uses: actions/checkout@v4 - name: environment setup - uses: conda-incubator/setup-miniconda@505e6394dae86d6a5c7fbb6e3fb8938e3e863830 # v3.1.1 + uses: conda-incubator/setup-miniconda@835234971496cad1653abb28a638a281cf32541f # v3.2.0 with: python-version: ${{ matrix.python-version }} channels: conda-forge From d0415302984acc69221707a23f96b5550c7a8d2a Mon Sep 17 00:00:00 2001 From: akrherz Date: Sat, 14 Jun 2025 07:54:51 -0500 Subject: [PATCH 28/51] Add python 3.13 to CI and metadata --- .github/workflows/ci.yml | 2 +- build_envs/environment.yml | 2 +- pyproject.toml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 686e41f..c487231 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,7 +24,7 @@ jobs: fail-fast: false matrix: os: [ "ubuntu-latest", "macos-latest", "macos-14" ] - python-version: [ "3.9", "3.10", "3.11", "3.12" ] + python-version: [ "3.9", "3.10", "3.11", "3.12", "3.13" ] steps: - name: checkout uses: actions/checkout@v4 diff --git a/build_envs/environment.yml b/build_envs/environment.yml index 6a6e7c9..a540f57 100644 --- a/build_envs/environment.yml +++ b/build_envs/environment.yml @@ -3,7 +3,7 @@ name: wrf_python_build channels: - conda-forge dependencies: - - python>=3.9, <3.13 + - python>=3.9, <3.14 - compilers - basemap - cartopy diff --git a/pyproject.toml b/pyproject.toml index 5047e19..2a882c8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -12,7 +12,7 @@ maintainers = [ ] description = "Diagnostic and interpolation routines for WRF-ARW data." readme = "README.md" -requires-python = ">=3.9, <3.13" +requires-python = ">=3.9, <3.14" keywords = [ "python", "wrf-python", "wrf", "forecast", "model", "weather research and forecasting", "interpolation", From 9d34c4a056aced422373612b166370c68628742a Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Thu, 17 Jul 2025 10:18:28 -0600 Subject: [PATCH 29/51] remove deprecated use of pkg_resources --- build_envs/environment.yml | 2 -- src/wrf/__init__.py | 20 ++------------------ 2 files changed, 2 insertions(+), 20 deletions(-) diff --git a/build_envs/environment.yml b/build_envs/environment.yml index a540f57..e889284 100644 --- a/build_envs/environment.yml +++ b/build_envs/environment.yml @@ -11,9 +11,7 @@ dependencies: - matplotlib - netcdf4 - numpy - - packaging - pycodestyle - - setuptools - sphinx - sphinx_rtd_theme - sphinxcontrib-googleanalytics diff --git a/src/wrf/__init__.py b/src/wrf/__init__.py index 39cd608..d848dd0 100644 --- a/src/wrf/__init__.py +++ b/src/wrf/__init__.py @@ -2,24 +2,8 @@ import os import pkg_resources -try: - from . import api - from .api import * -except ImportError: - # For gfortran+msvc combination, extra shared libraries may exist - # (stored by numpy.distutils) - if os.name == "nt": - req = pkg_resources.Requirement.parse("wrf-python") - extra_dll_dir = pkg_resources.resource_filename(req, - "wrf-python/.libs") - if os.path.isdir(extra_dll_dir): - os.environ["PATH"] += os.pathsep + extra_dll_dir - - from . import api - from .api import * - else: - raise - +from . import api +from .api import * __all__ = [] __all__.extend(api.__all__) From eec59cf140f6e492946e728bac78244679c638de Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Thu, 17 Jul 2025 10:22:19 -0600 Subject: [PATCH 30/51] remove import as well --- src/wrf/__init__.py | 1 - 1 file changed, 1 deletion(-) diff --git a/src/wrf/__init__.py b/src/wrf/__init__.py index d848dd0..99334d9 100644 --- a/src/wrf/__init__.py +++ b/src/wrf/__init__.py @@ -1,6 +1,5 @@ from __future__ import (absolute_import, division, print_function) import os -import pkg_resources from . import api from .api import * From d63d5d81eec227d7927f10e61c42ace22e49c195 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Aug 2025 05:14:23 +0000 Subject: [PATCH 31/51] Bump actions/checkout from 4 to 5 Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- .github/workflows/pypi.yaml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c487231..e16ac08 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -27,7 +27,7 @@ jobs: python-version: [ "3.9", "3.10", "3.11", "3.12", "3.13" ] steps: - name: checkout - uses: actions/checkout@v4 + uses: actions/checkout@v5 - name: environment setup uses: conda-incubator/setup-miniconda@835234971496cad1653abb28a638a281cf32541f # v3.2.0 with: diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml index b79509f..ef01061 100644 --- a/.github/workflows/pypi.yaml +++ b/.github/workflows/pypi.yaml @@ -8,7 +8,7 @@ jobs: if: github.repository == 'NCAR/wrf-python' runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Set up Python uses: actions/setup-python@v5 with: @@ -28,7 +28,7 @@ jobs: if: startsWith(github.ref, 'refs/tags') runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Set up Python uses: actions/setup-python@v5 with: From 701df45e9789589da3419652eda5ff3e33170bea Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Fri, 22 Aug 2025 12:56:05 -0600 Subject: [PATCH 32/51] Update docs to show lat lon labels and remove outdated note --- doc/source/plot.rst | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/doc/source/plot.rst b/doc/source/plot.rst index fb69a7f..19b7392 100644 --- a/doc/source/plot.rst +++ b/doc/source/plot.rst @@ -23,9 +23,6 @@ should be aware of a few shortcomings when working with WRF data. - The rotated pole projection requires the x and y limits to be set manually using set_xlim and set_ylim. -- You can't place latitude and longitude labels on the axes when using - any projection other than Mercator or LatLon. - Plotting a Two-dimensional Field ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -89,7 +86,10 @@ Plotting a Two-dimensional Field ax.set_ylim(cartopy_ylim(smooth_slp)) # Add the gridlines - ax.gridlines(color="black", linestyle="dotted") + gl = ax.gridlines(draw_labels=True, color="black", linestyle="dotted") + gl.right_labels = False + gl.x_inline = False + gl.top_labels = False plt.title("Sea Level Pressure (hPa)") From acbc96c6fae87aaf0a61b85e215e012dc2536fbd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Sep 2025 21:01:59 +0000 Subject: [PATCH 33/51] Bump actions/setup-python from 5 to 6 Bumps [actions/setup-python](https://github.com/actions/setup-python) from 5 to 6. - [Release notes](https://github.com/actions/setup-python/releases) - [Commits](https://github.com/actions/setup-python/compare/v5...v6) --- updated-dependencies: - dependency-name: actions/setup-python dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/pypi.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml index ef01061..2089a56 100644 --- a/.github/workflows/pypi.yaml +++ b/.github/workflows/pypi.yaml @@ -10,7 +10,7 @@ jobs: steps: - uses: actions/checkout@v5 - name: Set up Python - uses: actions/setup-python@v5 + uses: actions/setup-python@v6 with: python-version: '3.10' - name: Install dependencies @@ -30,7 +30,7 @@ jobs: steps: - uses: actions/checkout@v5 - name: Set up Python - uses: actions/setup-python@v5 + uses: actions/setup-python@v6 with: python-version: '3.10' - name: Install dependencies From 62f0443b568d1737b5542ce15f74e4f42021cdf7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Sep 2025 21:01:09 +0000 Subject: [PATCH 34/51] Bump pypa/gh-action-pypi-publish from 1.12.4 to 1.13.0 Bumps [pypa/gh-action-pypi-publish](https://github.com/pypa/gh-action-pypi-publish) from 1.12.4 to 1.13.0. - [Release notes](https://github.com/pypa/gh-action-pypi-publish/releases) - [Commits](https://github.com/pypa/gh-action-pypi-publish/compare/76f52bc884231f62b9a034ebfe128415bbaabdfc...ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e) --- updated-dependencies: - dependency-name: pypa/gh-action-pypi-publish dependency-version: 1.13.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/pypi.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml index 2089a56..cc57f0b 100644 --- a/.github/workflows/pypi.yaml +++ b/.github/workflows/pypi.yaml @@ -44,7 +44,7 @@ jobs: run: | python -m twine check dist/* - name: Publish package to PyPI - uses: pypa/gh-action-pypi-publish@76f52bc884231f62b9a034ebfe128415bbaabdfc # v1.12.4 + uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0 with: user: __token__ password: ${{ secrets.PYPI_WRF_PYTHON }} From a92c6c99c1651cc7455b6188b58a882165429e34 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Tue, 21 Oct 2025 14:44:13 -0700 Subject: [PATCH 35/51] fix for netCDF4 v1.7.3 iterator changes --- src/wrf/util.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/wrf/util.py b/src/wrf/util.py index 40229c7..03cb7a1 100644 --- a/src/wrf/util.py +++ b/src/wrf/util.py @@ -134,7 +134,13 @@ def is_multi_file(wrfin): is a single NetCDF file object. """ - return (isinstance(wrfin, Iterable) and not isstr(wrfin)) + try: + iter(wrfin) + is_iterable = True + except Exception: + is_iterable = False + + return (is_iterable and not isstr(wrfin)) def has_time_coord(wrfnc): From e21a7519a4113e8618b0aaea8d5fcea09043540b Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 22 Oct 2025 07:01:35 -0700 Subject: [PATCH 36/51] oops update the check to work for the older version of netcdf4 --- src/wrf/util.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/wrf/util.py b/src/wrf/util.py index 03cb7a1..99ef9ae 100644 --- a/src/wrf/util.py +++ b/src/wrf/util.py @@ -9,6 +9,7 @@ from types import GeneratorType import datetime as dt from inspect import getmodule +from netCDF4 import Dataset try: from inspect import signature @@ -134,10 +135,11 @@ def is_multi_file(wrfin): is a single NetCDF file object. """ - try: - iter(wrfin) + if isinstance(wrfin, Dataset): + is_iterable = False + elif isinstance(wrfin, Iterable): is_iterable = True - except Exception: + else: is_iterable = False return (is_iterable and not isstr(wrfin)) From 0221db74894700297250d95cec5a3a7f3ee072de Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Fri, 31 Oct 2025 14:47:13 -0600 Subject: [PATCH 37/51] Update Python version metadata to reflect support for 3.13 (#292) * update Python version info in pyproject.toml * remove Python version pin in macos-arm env * remove Python version pin * remove version pin for python --- build_envs/platform-specific/macos_arm64.yml | 2 +- build_envs/platform-specific/macos_x64.yml | 2 +- build_envs/platform-specific/windows.yml | 2 +- pyproject.toml | 1 + 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/build_envs/platform-specific/macos_arm64.yml b/build_envs/platform-specific/macos_arm64.yml index 2e475f0..d6483dd 100644 --- a/build_envs/platform-specific/macos_arm64.yml +++ b/build_envs/platform-specific/macos_arm64.yml @@ -3,7 +3,7 @@ name: wrf_python_build channels: - conda-forge dependencies: - - python<3.12 + - python - basemap - cartopy - clang_osx-arm64 diff --git a/build_envs/platform-specific/macos_x64.yml b/build_envs/platform-specific/macos_x64.yml index 2415ebe..ba798c2 100644 --- a/build_envs/platform-specific/macos_x64.yml +++ b/build_envs/platform-specific/macos_x64.yml @@ -3,7 +3,7 @@ name: wrf_python_build channels: - conda-forge dependencies: - - python<3.12 + - python - basemap - cartopy - clang_osx-64 diff --git a/build_envs/platform-specific/windows.yml b/build_envs/platform-specific/windows.yml index 1053db0..46d53b2 100644 --- a/build_envs/platform-specific/windows.yml +++ b/build_envs/platform-specific/windows.yml @@ -4,7 +4,7 @@ channels: - conda-forge - msys2 dependencies: - - python<3.12 + - python - basemap - cartopy - jupyter diff --git a/pyproject.toml b/pyproject.toml index 2a882c8..0f00bb5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -30,6 +30,7 @@ classifiers = [ "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", + "Programming Language :: Python :: 3.13", "Topic :: Scientific/Engineering :: Atmospheric Science", "Topic :: Software Development", "Operating System :: POSIX", From f3a632e5e0e304d9ab244ba4c3a5a41850b03cc4 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 5 Nov 2025 13:49:16 -0700 Subject: [PATCH 38/51] Release notes and version bump for v1.4.1 (#293) * Add release notes for version 1.4.1 * Bump version to 1.4.1 --- doc/source/new.rst | 9 +++++++++ src/wrf/version.py | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/doc/source/new.rst b/doc/source/new.rst index 364af0b..1035cae 100644 --- a/doc/source/new.rst +++ b/doc/source/new.rst @@ -4,6 +4,15 @@ What's New Releases ------------- +v1.4.1 (November 2025) +^^^^^^^^^^^^^^^^^^^^^^^^^ + +- Release 1.4.1 +- Support for Python 3.13 +- Fix to accommodate recent netCDF4 changes +- Remove pkg_resources +- Correct units for LCL and LFC in the subproduct diagnostics documentation + v1.4.0 (May 2025) ^^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/src/wrf/version.py b/src/wrf/version.py index 3e8d9f9..bf25615 100644 --- a/src/wrf/version.py +++ b/src/wrf/version.py @@ -1 +1 @@ -__version__ = "1.4.0" +__version__ = "1.4.1" From 18d55398e4dede6dfe659a02d054600151a09ae9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Nov 2025 20:10:24 +0000 Subject: [PATCH 39/51] Bump actions/checkout from 5 to 6 Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v5...v6) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- .github/workflows/pypi.yaml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e16ac08..c993972 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -27,7 +27,7 @@ jobs: python-version: [ "3.9", "3.10", "3.11", "3.12", "3.13" ] steps: - name: checkout - uses: actions/checkout@v5 + uses: actions/checkout@v6 - name: environment setup uses: conda-incubator/setup-miniconda@835234971496cad1653abb28a638a281cf32541f # v3.2.0 with: diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml index cc57f0b..19ffdff 100644 --- a/.github/workflows/pypi.yaml +++ b/.github/workflows/pypi.yaml @@ -8,7 +8,7 @@ jobs: if: github.repository == 'NCAR/wrf-python' runs-on: ubuntu-latest steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 - name: Set up Python uses: actions/setup-python@v6 with: @@ -28,7 +28,7 @@ jobs: if: startsWith(github.ref, 'refs/tags') runs-on: ubuntu-latest steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 - name: Set up Python uses: actions/setup-python@v6 with: From 91eb4b89468dcad80d3f7bcce72cb9b61ecc6a31 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 5 Nov 2025 19:48:18 -0700 Subject: [PATCH 40/51] Update Python versions in CI workflow --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c993972..e08cdd2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,7 +24,7 @@ jobs: fail-fast: false matrix: os: [ "ubuntu-latest", "macos-latest", "macos-14" ] - python-version: [ "3.9", "3.10", "3.11", "3.12", "3.13" ] + python-version: [ "3.10", "3.11", "3.12", "3.13", "3.14" ] steps: - name: checkout uses: actions/checkout@v6 From 0286804dede30eea71513e361a7d8bdd6366a614 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 5 Nov 2025 19:50:53 -0700 Subject: [PATCH 41/51] Remove Python version pin in environment.yml Updated Python version constraint to allow any version. --- build_envs/environment.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build_envs/environment.yml b/build_envs/environment.yml index e889284..27ab0a4 100644 --- a/build_envs/environment.yml +++ b/build_envs/environment.yml @@ -3,7 +3,7 @@ name: wrf_python_build channels: - conda-forge dependencies: - - python>=3.9, <3.14 + - python - compilers - basemap - cartopy From b25d6eb3bf73d6231b9d2da4c96aef3afbf012f2 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 5 Nov 2025 19:53:18 -0700 Subject: [PATCH 42/51] Update Python version requirements in pyproject.toml --- pyproject.toml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 0f00bb5..efc15bc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -12,7 +12,7 @@ maintainers = [ ] description = "Diagnostic and interpolation routines for WRF-ARW data." readme = "README.md" -requires-python = ">=3.9, <3.14" +requires-python = ">=3.10" keywords = [ "python", "wrf-python", "wrf", "forecast", "model", "weather research and forecasting", "interpolation", @@ -26,11 +26,12 @@ classifiers = [ "Intended Audience :: Developers", "License :: OSI Approved :: Apache Software License", "Programming Language :: Fortran", - "Programming Language :: Python :: 3.9", + "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", + "Programming Language :: Python :: 3.14", "Topic :: Scientific/Engineering :: Atmospheric Science", "Topic :: Software Development", "Operating System :: POSIX", From 346a9aa9739d03f072d19af83cca9403259039f9 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 5 Nov 2025 20:03:17 -0700 Subject: [PATCH 43/51] Just kidding on 3.14 --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index efc15bc..da4ae17 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -31,7 +31,6 @@ classifiers = [ "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", - "Programming Language :: Python :: 3.14", "Topic :: Scientific/Engineering :: Atmospheric Science", "Topic :: Software Development", "Operating System :: POSIX", From 926b953187da6196a78d4d4c72410156a3d8f556 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 5 Nov 2025 20:03:55 -0700 Subject: [PATCH 44/51] Drop Python 3.14 from CI workflow Removed Python version 3.14 from CI workflow matrix. --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e08cdd2..302a8f1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,7 +24,7 @@ jobs: fail-fast: false matrix: os: [ "ubuntu-latest", "macos-latest", "macos-14" ] - python-version: [ "3.10", "3.11", "3.12", "3.13", "3.14" ] + python-version: [ "3.10", "3.11", "3.12", "3.13" ] steps: - name: checkout uses: actions/checkout@v6 From 27832f0e40a5baa49c73cb3e35456c32e6901568 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Thu, 18 Dec 2025 12:54:36 -0700 Subject: [PATCH 45/51] Add release notes for version 1.4.2 Updated release notes for version 1.4.2. --- doc/source/new.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/doc/source/new.rst b/doc/source/new.rst index 1035cae..03eb680 100644 --- a/doc/source/new.rst +++ b/doc/source/new.rst @@ -4,6 +4,10 @@ What's New Releases ------------- +v1.4.2 (December 2025) +- Release 1.4.2 +- Remove Python upper version pin and drop Python 3.9 + v1.4.1 (November 2025) ^^^^^^^^^^^^^^^^^^^^^^^^^ From 95e8e216f46221752efec372831137528894030b Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Thu, 18 Dec 2025 12:55:03 -0700 Subject: [PATCH 46/51] Bump version from 1.4.1 to 1.4.2 --- src/wrf/version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wrf/version.py b/src/wrf/version.py index bf25615..daa50c7 100644 --- a/src/wrf/version.py +++ b/src/wrf/version.py @@ -1 +1 @@ -__version__ = "1.4.1" +__version__ = "1.4.2" From 59018ff058cdd43bbfa3ed0696383162a2faa0c0 Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Mon, 5 Jan 2026 09:59:52 -0700 Subject: [PATCH 47/51] Installation docs updates (#306) * update README * first round of install docs updates * update install docs --- README.md | 15 ++--- doc/source/installation.rst | 123 +++++------------------------------- 2 files changed, 20 insertions(+), 118 deletions(-) diff --git a/README.md b/README.md index 13f6420..a39aaba 100644 --- a/README.md +++ b/README.md @@ -9,26 +9,21 @@ This package provides over 30 diagnostic calculations, several interpolation rou Installation ---------------------------- - conda install -c conda-forge wrf-python + conda install conda-forge::wrf-python Documentation ---------------------------------- -http://wrf-python.rtfd.org +https://wrf-python.readthedocs.io Citation ------------------ -If you use this software, please cite it as described at the [WRF-Python - Citation]( -https://wrf-python.readthedocs.io/en/latest/citation.html) page. +If you use this software, please cite it as described in the [documentation]( +https://wrf-python.readthedocs.io/en/latest/citation.html). -------------------- -*The National Center for Atmospheric Research is sponsored by the National -Science Foundation. Any opinions, findings and conclusions or recommendations -expressed in this material do not necessarily reflect the views of the -National Science Foundation.* - - +*This material is based upon work supported by the NSF National Center for Atmospheric Research, a major facility sponsored by the U.S. National Science Foundation and managed by the University Corporation for Atmospheric Research. Any opinions, findings and conclusions or recommendations expressed in this material do not necessarily reflect the views of the U.S. National Science Foundation.* diff --git a/doc/source/installation.rst b/doc/source/installation.rst index c35c7fc..016515e 100644 --- a/doc/source/installation.rst +++ b/doc/source/installation.rst @@ -1,139 +1,46 @@ Installation ============ -Required Dependencies ----------------------- - - - Python 3.9+ - - numpy (1.11 or later; 1.14 required to build on Windows) - - wrapt (1.10 or later) - - setuptools (38.0 or later) - - -Highly Recommended Packages ----------------------------- - - - xarray (0.7.0 or later) - - PyNIO (1.4.3 or later) - - netCDF4-python (1.2.0 or later) - - -Plotting Packages -------------------------- - - - PyNGL (1.4.3 or later) - - matplotlib (1.4.3 or later) - - cartopy (0.13 or later) - - basemap (1.0.8 or later) - - Installing via Conda --------------------- The easiest way to install wrf-python is using -`Conda `_:: +`Conda `_:: - conda install -c conda-forge wrf-python + conda install conda-forge::wrf-python .. note:: - If you use conda to install wrf-python on a supercomputer like - Yellowstone or Cheyenne, we recommend that you do not load any python + If you use Conda to install WRF-Python on a supercomputer like + Derecho or Casper, we recommend that you do not load any Python related modules via the 'module load' command. The packages installed - by the 'module load' system will not play nicely with packages installed - via conda. + by the 'module load' system may not play nicely with packages installed + via Conda. - Further, some systems will install python packages to a ~/.local directory, - which will be found by the miniconda python interpreter and cause various + Further, some systems will install Python packages to a ~/.local directory, + which will be found by the Conda Python interpreter and cause various import problems. If you have a ~/.local directory, we strongly suggest renaming it (mv ~/.local ~/.local_backup). -Installing on Yellowstone ----------------------------- - -On Yellowstone, wrf-python can also be installed using the module load system, -if this is preferred over using conda. - -Unfortunately, because wrf-python requires newer dependencies, it is not -available using the 'all-python-libs' module, so many of the dependencies -need to be manually installed (most are for xarray). - -Also, make sure you are running in the gnu/4.8.2 compiler environment or -you will get import errors for a missing libquadmath library when you -go to import wrf-python. - -To install:: +WRF-Python on NSF NCAR HPC +-------------------------- - module load gnu/4.8.2 or module swap intel gnu/4.8.2 - module load python/2.7.7 - module load numpy/1.11.0 wrapt/1.10.10 scipy/0.17.1 bottleneck/1.1.0 numexpr/2.6.0 pyside/1.1.2 matplotlib/1.5.1 pandas/0.18.1 netcdf4python/1.2.4 xarray/0.8.2 - module load wrf-python/1.0.1 +WRF-Python is included in the `NCAR Python Library `_ on the NSF NCAR HPC systems or can be installed using a supported package manager of your choice. Installing via Source Code -------------------------- Installation via source code will require a Fortran and C compiler in order -to run f2py. You can get them -`here `_. +to run F2PY. -The source code is available via github: +The source code is available on GitHub: https://github.com/NCAR/wrf-python -Or PyPI: - -https://pypi.python.org/pypi/wrf-python - -To install, if you do not need OpenMP support, change your working directory +To install, change your working directory to the wrf-python source directory and run:: $ pip install . - -Beginning with wrf-python 1.1, OpenMP is supported, but preprocessing the -ompgen.F90 file is required, which also requires running f2py to -build the .pyf file. To simplify this process, you can use the build scripts in -the *build_scripts* directory as a guide, or just call the script directly. - -Below is a sample from a build script for GNU compiler with OpenMP enabled: - -.. code-block:: none - - cd ../fortran/build_help - - gfortran -o sizes -fopenmp omp_sizes.f90 - - python sub_sizes.py - - cd .. - - gfortran -E ompgen.F90 -fopenmp -cpp -o omp.f90 - - f2py *.f90 -m _wrffortran -h wrffortran.pyf --overwrite-signature - - cd .. - - python setup.py clean --all - - python setup.py config_fc --f90flags="-mtune=generic -fopenmp" build_ext --libraries="gomp" build - - pip install . - -Beginning with numpy 1.14, f2py extensions can now be built using the MSVC -compiler and mingw gfortran compiler. Numpy 1.14 is required to build -wrf-python for Python 3.5+. - -.. note:: - - If you are building on a supercomputer and receiving linker related - errors (e.g. missing symbols, undefined references, etc), you probably - need to unset the LDFLAGS environment variable. System administrators on - supercomputing systems often define LDFLAGS for you so that you don't need - to worry about where libraries like NetCDF are installed. Unfortunately, - this can cause problems with the numpy.distutils build system. To fix, - using the build command from above:: - - $ unset LDFLAGS python setup.py config_fc --f90flags="-mtune=generic -fopenmp" build_ext --libraries="gomp" build - - + From 2b7ab2575170324fb8051f77afb9f4b1f8fe4333 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Jan 2026 15:11:21 -0700 Subject: [PATCH 48/51] Bump conda-incubator/setup-miniconda from 3.2.0 to 3.3.0 (#308) Bumps [conda-incubator/setup-miniconda](https://github.com/conda-incubator/setup-miniconda) from 3.2.0 to 3.3.0. - [Release notes](https://github.com/conda-incubator/setup-miniconda/releases) - [Changelog](https://github.com/conda-incubator/setup-miniconda/blob/main/CHANGELOG.md) - [Commits](https://github.com/conda-incubator/setup-miniconda/compare/835234971496cad1653abb28a638a281cf32541f...fc2d68f6413eb2d87b895e92f8584b5b94a10167) --- updated-dependencies: - dependency-name: conda-incubator/setup-miniconda dependency-version: 3.3.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 302a8f1..6f18e2b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,7 +29,7 @@ jobs: - name: checkout uses: actions/checkout@v6 - name: environment setup - uses: conda-incubator/setup-miniconda@835234971496cad1653abb28a638a281cf32541f # v3.2.0 + uses: conda-incubator/setup-miniconda@fc2d68f6413eb2d87b895e92f8584b5b94a10167 # v3.3.0 with: python-version: ${{ matrix.python-version }} channels: conda-forge From d90b15cd7308da44c5104874a01f96fc9857e212 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Apr 2026 15:34:47 -0600 Subject: [PATCH 49/51] Bump pypa/gh-action-pypi-publish from 1.13.0 to 1.14.0 (#310) Bumps [pypa/gh-action-pypi-publish](https://github.com/pypa/gh-action-pypi-publish) from 1.13.0 to 1.14.0. - [Release notes](https://github.com/pypa/gh-action-pypi-publish/releases) - [Commits](https://github.com/pypa/gh-action-pypi-publish/compare/ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e...cef221092ed1bacb1cc03d23a2d87d1d172e277b) --- updated-dependencies: - dependency-name: pypa/gh-action-pypi-publish dependency-version: 1.14.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/pypi.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml index 19ffdff..9206c63 100644 --- a/.github/workflows/pypi.yaml +++ b/.github/workflows/pypi.yaml @@ -44,7 +44,7 @@ jobs: run: | python -m twine check dist/* - name: Publish package to PyPI - uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0 + uses: pypa/gh-action-pypi-publish@cef221092ed1bacb1cc03d23a2d87d1d172e277b # v1.14.0 with: user: __token__ password: ${{ secrets.PYPI_WRF_PYTHON }} From 8fc2a540d134365b12688df05c802de8ab66433b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 27 Apr 2026 18:01:44 -0600 Subject: [PATCH 50/51] Bump conda-incubator/setup-miniconda from 3.3.0 to 4.0.1 (#311) Bumps [conda-incubator/setup-miniconda](https://github.com/conda-incubator/setup-miniconda) from 3.3.0 to 4.0.1. - [Release notes](https://github.com/conda-incubator/setup-miniconda/releases) - [Changelog](https://github.com/conda-incubator/setup-miniconda/blob/main/CHANGELOG.md) - [Commits](https://github.com/conda-incubator/setup-miniconda/compare/fc2d68f6413eb2d87b895e92f8584b5b94a10167...8ee1f361103df19b6f8c8655fd3967a8ecb162d5) --- updated-dependencies: - dependency-name: conda-incubator/setup-miniconda dependency-version: 4.0.1 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6f18e2b..5e36cb3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,7 +29,7 @@ jobs: - name: checkout uses: actions/checkout@v6 - name: environment setup - uses: conda-incubator/setup-miniconda@fc2d68f6413eb2d87b895e92f8584b5b94a10167 # v3.3.0 + uses: conda-incubator/setup-miniconda@8ee1f361103df19b6f8c8655fd3967a8ecb162d5 # v4.0.1 with: python-version: ${{ matrix.python-version }} channels: conda-forge From 5b1c1c858b6abf7a8919af123cc91575ed996c4d Mon Sep 17 00:00:00 2001 From: Katelyn FitzGerald <7872563+kafitzgerald@users.noreply.github.com> Date: Wed, 24 Jun 2026 13:29:54 -0600 Subject: [PATCH 51/51] Update Read the Docs configuration for latest OS and Python (#313) --- .readthedocs.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.readthedocs.yml b/.readthedocs.yml index 8cb6480..abbbbb8 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -6,9 +6,9 @@ version: 2 build: - os: "ubuntu-20.04" + os: "ubuntu-lts-latest" tools: - python: "mambaforge-4.10" + python: "miniforge3-latest" jobs: post_create_environment: - python -m pip install --no-cache-dir --no-deps .