CircleCI-Public / cimg-python

The Next-Gen CircleCI Python Docker Convenience Image.
https://circleci.com/developer/images/image/cimg/python
MIT License
32 stars 30 forks source link

Bug Report: pyenv shell integrations not enabled #220

Open cjw296 opened 10 months ago

cjw296 commented 10 months ago

Describe the bug

While pyenv is used to build these images, the shell integrations are missing.

What this means is that if you install a package that provides a console script, such as pytest, the console script will not be available in your Circle CI jobs.

To Reproduce

A job with the following steps will do it:

      - run:
          name: "Install PyTest"
          command: "python -m pip install pytest"
      - run:
          name: "Run PyTest"
          command: "pytest --help"

Expected behavior

I'd expect the pytest help message to be printed.

Workarounds

I'm going to try python -m pytest instead.

jasonyoung-pearl commented 5 months ago

We had a similar issue. When using tfenv in CircleCI, export PATH=$HOME/.tfenv/bin:$PATH would entirely break pyenv. Instead we had to symlink tfenv and terraform binaries to a path that already existed in PATH.