Skip to content

Commit

Permalink
Drop pin_compatible('numpy')
Browse files Browse the repository at this point in the history
This is no longer needed as `numpy` has `run_exports`.
  • Loading branch information
jakirkham committed Aug 13, 2024
1 parent 5aaf25e commit ea19493
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion grayskull/strategy/py_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@

log = logging.getLogger(__name__)
RE_DEPS_NAME = re.compile(r"^\s*([\.a-zA-Z0-9_-]+)", re.MULTILINE)
PIN_PKG_COMPILER = {"numpy": "<{ pin_compatible('numpy') }}"}
PIN_PKG_COMPILER = {}


def search_setup_root(path_folder: Union[Path, str]) -> Path:
Expand Down
3 changes: 1 addition & 2 deletions tests/test_py_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,7 @@ def test_update_requirements_with_pin_mixed_numpy_pin_compatible():
"run": ["numpy >=1.19.1,<2.0.0", "pyparsing >=2.4.7, <3.0.0", "python"],
}
update_requirements_with_pin(requirements)
assert "<{ pin_compatible('numpy') }}" in requirements["run"]
assert "numpy" not in requirements["run"]
assert "numpy >=1.19.1,<2.0.0" in requirements["run"]


def test_ensure_pep440_stripping_empty_spaces():
Expand Down
6 changes: 3 additions & 3 deletions tests/test_pypi.py
Original file line number Diff line number Diff line change
Expand Up @@ -681,7 +681,7 @@ def test_update_requirements_with_pin():
assert req == {
"build": ["<{ compiler('c') }}"],
"host": ["python", "numpy"],
"run": ["python", "<{ pin_compatible('numpy') }}"],
"run": ["python", "numpy"],
}


Expand Down Expand Up @@ -815,7 +815,7 @@ def test_ciso_recipe():
["cython", "numpy", "pip", "python"]
)
assert sorted(recipe["requirements"]["run"]) == sorted(
["cython", "python", "<{ pin_compatible('numpy') }}"]
["cython", "python", "numpy"]
)
assert recipe["test"]["commands"] == ["pip check"]
assert recipe["test"]["requires"] == ["pip"]
Expand All @@ -834,7 +834,7 @@ def test_pymc_recipe_fortran():
}
assert set(recipe["requirements"]["host"]) == {"numpy", "python", "pip"}
assert set(recipe["requirements"]["run"]) == {
"<{ pin_compatible('numpy') }}",
"numpy",
"python",
}
assert not recipe["build"]["noarch"]
Expand Down

0 comments on commit ea19493

Please sign in to comment.