From d18d276bbf111ac5ba91fe65a24558fc05730b2a Mon Sep 17 00:00:00 2001 From: "Harlow, Jordan" Date: Thu, 19 Mar 2026 13:04:53 -0600 Subject: [PATCH 1/4] chore: meta.yaml to accommodate numpy-base or numpy --- conda-recipe-cf/meta.yaml | 2 +- conda-recipe/meta.yaml | 13 +++++++++++-- docs/source/conf.py | 2 +- mkl_random/_version.py | 2 +- 4 files changed, 14 insertions(+), 5 deletions(-) diff --git a/conda-recipe-cf/meta.yaml b/conda-recipe-cf/meta.yaml index 47c4634..6eefee6 100644 --- a/conda-recipe-cf/meta.yaml +++ b/conda-recipe-cf/meta.yaml @@ -1,4 +1,4 @@ -{% set version = "1.4.0dev1" %} +{% set version = "1.4.0dev3" %} {% set buildnumber = 0 %} package: diff --git a/conda-recipe/meta.yaml b/conda-recipe/meta.yaml index 6877fec..b7382a3 100644 --- a/conda-recipe/meta.yaml +++ b/conda-recipe/meta.yaml @@ -1,3 +1,5 @@ +{% set use_numpy_base = environ.get('USE_NUMPY_BASE', 'true').lower() == 'true' %} + package: name: mkl_random version: {{ GIT_DESCRIBE_TAG }} @@ -23,14 +25,21 @@ requirements: - setuptools >=77 - mkl-devel - cython + {% if use_numpy_base %} - numpy-base + {% else %} + - numpy >=1.26.4 + {% endif %} - pip - wheel >=0.41.3 run: - python - python-gil # [py>=314] - - {{ pin_compatible('mkl', min_pin="x.x", max_pin="x") }} - - {{ pin_compatible('numpy-base', min_pin="x.x", max_pin="x") }} + {% if use_numpy_base %} + - numpy-base + {% else %} + - numpy >=1.26.4 + {% endif %} test: commands: diff --git a/docs/source/conf.py b/docs/source/conf.py index 666e0b3..a46a611 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -9,7 +9,7 @@ project = "mkl_random" copyright = "2017-2025, Intel Corp." author = "Intel Corp." -release = "1.4.0dev1" +release = "1.4.0dev3" # -- General configuration --------------------------------------------------- # https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration diff --git a/mkl_random/_version.py b/mkl_random/_version.py index 2e16e46..94d7004 100644 --- a/mkl_random/_version.py +++ b/mkl_random/_version.py @@ -1 +1 @@ -__version__ = "1.4.0dev1" +__version__ = "1.4.0dev3" From 73f4f422a0c786ab04e076dcf7cb511bd326e693 Mon Sep 17 00:00:00 2001 From: "Harlow, Jordan" Date: Mon, 23 Mar 2026 13:42:38 -0600 Subject: [PATCH 2/4] fix: review --- conda-recipe-cf/meta.yaml | 3 --- conda-recipe/meta.yaml | 1 + 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/conda-recipe-cf/meta.yaml b/conda-recipe-cf/meta.yaml index 2f701d8..ba58267 100644 --- a/conda-recipe-cf/meta.yaml +++ b/conda-recipe-cf/meta.yaml @@ -1,6 +1,3 @@ -{% set version = "1.4.0dev3" %} -{% set buildnumber = 0 %} - package: name: mkl_random version: {{ GIT_DESCRIBE_TAG }} diff --git a/conda-recipe/meta.yaml b/conda-recipe/meta.yaml index b7382a3..296281e 100644 --- a/conda-recipe/meta.yaml +++ b/conda-recipe/meta.yaml @@ -35,6 +35,7 @@ requirements: run: - python - python-gil # [py>=314] + - {{ pin_compatible('mkl', min_pin="x.x", max_pin="x") }} {% if use_numpy_base %} - numpy-base {% else %} From 68a958cd9b25a5946369f970fbabddf3b2bd17f8 Mon Sep 17 00:00:00 2001 From: "Harlow, Jordan" Date: Mon, 23 Mar 2026 14:51:10 -0600 Subject: [PATCH 3/4] fix: tweak numpy host constraint --- conda-recipe/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conda-recipe/meta.yaml b/conda-recipe/meta.yaml index 296281e..1db0be2 100644 --- a/conda-recipe/meta.yaml +++ b/conda-recipe/meta.yaml @@ -28,7 +28,7 @@ requirements: {% if use_numpy_base %} - numpy-base {% else %} - - numpy >=1.26.4 + - numpy {% endif %} - pip - wheel >=0.41.3 From 38f60a422290697e51e10a02dd62ac7a52b838e2 Mon Sep 17 00:00:00 2001 From: "Harlow, Jordan" Date: Mon, 23 Mar 2026 14:52:10 -0600 Subject: [PATCH 4/4] fix: changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 9828788..e54ecab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed * Updates to `mkl_random` implementations to better align with newer versions of `numpy.random` [gh-103](https://github.com/IntelPython/mkl_random/pull/103) +* Made conda recipe dependency on numpy configurable through `USE_NUMPY_BASE` environment variable [gh-105](https://github.com/IntelPython/mkl_random/pull/105) ### Fixed * Various bugfixes including a hang in `zipf` when called with `np.nan` and size-1 1D arrays being cast to scalars [gh-103](https://github.com/IntelPython/mkl_random/pull/103)