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

PIP_NO_BUILD_ISOLATION not set in build environment #3318

Closed
jjhelmus opened this issue Dec 13, 2018 · 3 comments · Fixed by #3319
Closed

PIP_NO_BUILD_ISOLATION not set in build environment #3318

jjhelmus opened this issue Dec 13, 2018 · 3 comments · Fixed by #3319
Labels
locked [bot] locked due to inactivity

Comments

@jjhelmus
Copy link
Contributor

Despite the being specified in build.py, #3053, PIP_NO_BUILD_ISOLATION is not being set in the build/host environment.

package:
  name: foobar
  version: 1.0.0

build:
  script:
    - env | grep PIP_NO
    - exit 1
$ conda build --version
read filter "zstd" is not supported
write filter "zstd" is not supported
conda-build 3.17.4
$ conda build .
...
BUILD START: ['foobar-1.0.0-0.tar.bz2']
source tree in: /home/jhelmus/anaconda3/conda-bld/foobar_1544729597284/work
export PREFIX=/home/jhelmus/anaconda3/conda-bld/foobar_1544729597284/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_pla
export SRC_DIR=/home/jhelmus/anaconda3/conda-bld/foobar_1544729597284/work
PIP_NO_INDEX=True
PIP_NO_DEPENDENCIES=True
Traceback (most recent call last):
@jjhelmus
Copy link
Contributor Author

jjhelmus commented Dec 13, 2018

This causes issues building projects which have a pyproject.yaml file, for discussion see conda-forge/betse-feedstock#10

@jjhelmus
Copy link
Contributor Author

Looks like the environment values are only written if they evaluate to truthy, so falsy values, including False are not written.

    with open(env_file, 'w') as bf:
        for k, v in env.items():
            if v:
                bf.write('export {0}="{1}"\n'.format(k, v))

jjhelmus added a commit to jjhelmus/conda-build that referenced this issue Dec 13, 2018
The environment variable PIP_NO_BUILD_ISOLATION is set to 'False' in the
build environment.  Previously this variable was not set in the environment
due to it having a falsey value. It is now set to the string 'False' so that it
has a truethy value in Python which results in in being included in the
environment file.

closes conda#3318
leycec added a commit to conda-forge/betse-feedstock that referenced this issue Dec 14, 2018
BETSE 0.9.1 bumped.

Heartfelt thanks to @jjhelmus, @ocefpaf, @CJ-Wright, and the dedicated conda-forge community for uncovering the eldritch horrors that lurk beneath conda/conda-build#3318.
leycec added a commit to regro-cf-autotick-bot/betsee-feedstock that referenced this issue Dec 14, 2018
leycec added a commit to conda-forge/betsee-feedstock that referenced this issue Dec 14, 2018
BETSEE 0.9.1.0 bumped.

Heartfelt thanks to @jjhelmus, @ocefpaf, @CJ-Wright, and the dedicated conda-forge community for uncovering the eldritch horrors that lurk beneath conda/conda-build#3318.
mingwandroid pushed a commit to mingwandroid/conda-build that referenced this issue Jan 28, 2019
The environment variable PIP_NO_BUILD_ISOLATION is set to 'False' in the
build environment.  Previously this variable was not set in the environment
due to it having a falsey value. It is now set to the string 'False' so that it
has a truethy value in Python which results in in being included in the
environment file.

closes conda#3318
@github-actions
Copy link

Hi there, thank you for your contribution!

This issue has been automatically locked because it has not had recent activity after being closed.

Please open a new issue if needed.

Thanks!

@github-actions github-actions bot added the locked [bot] locked due to inactivity label Mar 11, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 11, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
locked [bot] locked due to inactivity
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant