From a916063425d47be001ba1be4db5999624f526c12 Mon Sep 17 00:00:00 2001 From: zacharyburnett Date: Mon, 6 May 2024 12:29:45 -0400 Subject: [PATCH 1/3] add test command to import c extension modules --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 96b0d920..a02c61e4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -23,5 +23,6 @@ jobs: # Until we have arm64 runners, we can't automatically test arm64 wheels - cp3*-macosx_arm64 sdist: true + test_command: python -c "from stcal.ramp_fitting import ols_cas22._ramp, ols_cas22._jump, ols_cas22._fit" secrets: pypi_token: ${{ secrets.PYPI_PASSWORD_STSCI_MAINTAINER }} From 9f6f18df4f4411ff34233b829a7271b453997ec3 Mon Sep 17 00:00:00 2001 From: zacharyburnett Date: Mon, 6 May 2024 13:02:02 -0400 Subject: [PATCH 2/3] add comment about test_command in cibuildwheel --- setup.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/setup.py b/setup.py index e176149e..686c3ee8 100644 --- a/setup.py +++ b/setup.py @@ -6,6 +6,8 @@ Options.docstrings = True Options.annotate = False +# importing these extension modules is tested in `.github/workflows/build.yml`; +# when adding new modules here, make sure to add them to the `test_command` entry there extensions = [ Extension( "stcal.ramp_fitting.ols_cas22._ramp", From 216c0a79f43bcdf25817e239781722b7bb8d2cef Mon Sep 17 00:00:00 2001 From: zacharyburnett Date: Mon, 6 May 2024 13:06:01 -0400 Subject: [PATCH 3/3] fix import syntax --- .github/workflows/build.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a02c61e4..f40da251 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -23,6 +23,6 @@ jobs: # Until we have arm64 runners, we can't automatically test arm64 wheels - cp3*-macosx_arm64 sdist: true - test_command: python -c "from stcal.ramp_fitting import ols_cas22._ramp, ols_cas22._jump, ols_cas22._fit" + test_command: python -c "from stcal.ramp_fitting.ols_cas22 import _ramp, _jump, _fit" secrets: pypi_token: ${{ secrets.PYPI_PASSWORD_STSCI_MAINTAINER }}