Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Remove 'pip install' options in recipes #5541

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions conda_build/skeletons/pypi.py
Original file line number Diff line number Diff line change
Expand Up @@ -431,9 +431,7 @@ def skeletonize(
if noarch_python:
ordered_recipe["build"]["noarch"] = "python"

recipe_script_cmd = [
"{{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation"
]
recipe_script_cmd = ["{{ PYTHON }} -m pip install . -vv"]
ordered_recipe["build"]["script"] = " ".join(
recipe_script_cmd + setup_options
)
Expand Down
2 changes: 1 addition & 1 deletion conda_build/templates/setuptools.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ build:
number: {% block build_number -%}1{%- endblock %}
script:
- cd $RECIPE_DIR
- pip install --no-deps .
- pip install .

{% block entry_points -%}
entry_points: {{data.get('entry_points', {}).get('console_scripts', [])}}
Expand Down
2 changes: 1 addition & 1 deletion docs/click/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ source:

build:
number: 0
script: "{{ PYTHON }} -m pip install . --no-deps --ignore-installed -vv "
script: "{{ PYTHON }} -m pip install . -vv "

requirements:
host:
Expand Down
2 changes: 1 addition & 1 deletion docs/source/resources/define-metadata.rst
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ All the metadata in the conda-build recipe is specified in the
build:
noarch: python
number: 0
script: python -m pip install --no-deps --ignore-installed .
script: python -m pip install .

requirements:
host:
Expand Down
2 changes: 1 addition & 1 deletion docs/source/user-guide/tutorials/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ source:

build:
number: 0
script: "{{ PYTHON }} -m pip install . --no-deps --ignore-installed -vv "
script: "{{ PYTHON }} -m pip install . -vv "

requirements:
host:
Expand Down
5 changes: 5 additions & 0 deletions news/5541-remove-pip-install-options-from-recipes
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
### Other

* Remove `--no-deps`, `--no-build-isolation`, and `--ignore-installed`
`pip install` options in example recipes as `conda-build` will enforce
all required `pip install` options itself at build time. (#5541)
2 changes: 1 addition & 1 deletion recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ source:
git_url: ../

build:
script: {{ PYTHON }} -m pip install . --no-deps --no-build-isolation -vv
script: {{ PYTHON }} -m pip install . -vv
entry_points:
- conda-build = conda_build.cli.main_build:execute
- conda-convert = conda_build.cli.main_convert:execute
Expand Down
2 changes: 1 addition & 1 deletion tests/test-recipes/metadata/_noarch_none/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ source:
path: ./noarch_test_package

build:
script: pip install --no-deps .
script: pip install .
noarch: none

requirements:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ source:

build:
number: 0
script: "{{ PYTHON }} -m pip install . --no-deps --ignore-installed -vv "
script: "{{ PYTHON }} -m pip install . -vv "

requirements:
host:
Expand Down
2 changes: 1 addition & 1 deletion tests/test-recipes/metadata/_render_recipe/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ build:
script:
- {{ PYTHON }} conf/cythonize.py
- export PETSC_DIR=$PREFIX
- {{ PYTHON }} -m pip -v install --no-deps .
- {{ PYTHON }} -m pip -v install .
skip: true # [win]
track_features:
- petsc4py_complex # [scalar == "complex"]
Expand Down
2 changes: 1 addition & 1 deletion tests/test-recipes/metadata/entry_points/bld.bat
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
:: cd %RECIPE_DIR%\..\..\test-package
:: pip install --no-deps .
:: pip install .
python setup.py install --old-and-unmanageable
if errorlevel 1 exit 1
2 changes: 1 addition & 1 deletion tests/test-recipes/metadata/entry_points/build.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# conda-build/tests/test-recipes/test-package
# cd $RECIPE_DIR/../../test-package

# pip install --no-deps .
# pip install .
python setup.py install --old-and-unmanageable
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ source:
build:
number: 0
script:
- {{ PYTHON }} -m pip install . --no-deps --ignore-installed --no-cache-dir -vvv
- {{ PYTHON }} -m pip install . -vvv

requirements:
host:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ build:
noarch: python
skip: True # [win]
script:
- {{ PYTHON }} -m pip install . --no-deps --ignore-installed --no-cache-dir -vvv
- {{ PYTHON }} -m pip install . -vvv
# We use 'somewhere' instead of 'bin' here because conda-build is quite broken in what it considers
# and entry point script when you use noarch: python, involving finding files in 'bin' that contain
# prefix and making assumptions about that (we could check for python in the shebang at least, but
Expand Down
2 changes: 1 addition & 1 deletion tests/test-recipes/metadata/jinja_load_toml/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,5 @@ requirements:
{% endfor %}

build:
script: {{ PYTHON }} -m pip install --no-deps --ignore-installed .
script: {{ PYTHON }} -m pip install .
noarch: python
2 changes: 1 addition & 1 deletion tests/test-recipes/metadata/jinja_load_yaml/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@ requirements:
{% endfor %}

build:
script: {{ PYTHON }} -m pip install --no-deps --ignore-installed .
script: {{ PYTHON }} -m pip install .
noarch: python
4 changes: 2 additions & 2 deletions tests/test_pypi_skeleton.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def test_print_dict():
},
"build": {
"number": 0,
"script": "{{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation",
"script": "{{ PYTHON }} -m pip install . -vv",
},
}
recipe_order = ["package", "source", "build", "about"]
Expand All @@ -74,7 +74,7 @@ def test_print_dict():

build:
number: 0
script: "{{ PYTHON }} -m pip install . -vv --no-deps --no-build-isolation"
script: "{{ PYTHON }} -m pip install . -vv"

about:
home: "https://conda.io"
Expand Down
Loading