From 70c7c1140b6a56cf956af24a9e7864a4da0d4a54 Mon Sep 17 00:00:00 2001 From: Cadair <1391051+Cadair@users.noreply.github.com> Date: Mon, 20 Jan 2025 07:05:47 +0000 Subject: [PATCH 1/2] Automatic package template update --- .cruft.json | 4 ++-- .pre-commit-config.yaml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.cruft.json b/.cruft.json index e14d07e6c..f2b685911 100644 --- a/.cruft.json +++ b/.cruft.json @@ -1,6 +1,6 @@ { "template": "https://github.com/sunpy/package-template", - "commit": "d6b86e07efa31959f43e99ba32d323cf76736a05", + "commit": "ff0522bc171a1fc63022ed2a371f70669173012e", "checkout": null, "context": { "cookiecutter": { @@ -32,7 +32,7 @@ ".github/workflows/sub_package_update.yml" ], "_template": "https://github.com/sunpy/package-template", - "_commit": "d6b86e07efa31959f43e99ba32d323cf76736a05" + "_commit": "ff0522bc171a1fc63022ed2a371f70669173012e" } }, "directory": null diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 906495f97..a7d7dd5cb 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,7 +1,7 @@ repos: # This should be before any formatting hooks like isort - repo: https://github.com/astral-sh/ruff-pre-commit - rev: "v0.8.6" + rev: "v0.9.1" hooks: - id: ruff args: ["--fix"] From 8138856baae8abf814d4a433dd1fa1a1ff410543 Mon Sep 17 00:00:00 2001 From: Nabil Freij Date: Sun, 19 Jan 2025 23:42:56 -0800 Subject: [PATCH 2/2] Update cube.py --- ndcube/utils/cube.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ndcube/utils/cube.py b/ndcube/utils/cube.py index 31e020c06..ce8ab6233 100644 --- a/ndcube/utils/cube.py +++ b/ndcube/utils/cube.py @@ -261,7 +261,7 @@ def propagate_rebin_uncertainties(uncertainty, data, mask, operation, operation_ if operation in {np.sum, np.nansum, np.mean, np.nanmean}: propagation_operation = np.add # TODO: product was renamed to prod for numpy 2.0 - elif operation in {np.prod, np.nanprod, np.prod if hasattr(np, "product") else np.prod}: + elif operation in {np.prod, np.nanprod}: propagation_operation = np.multiply else: raise ValueError("propagation_operation not recognized.")