saltstack / saltstack/salt

pip.installed can only install to the default location

Open
#61,249 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug dependency Deprecation severity-medium
Dominant language
Python
Stars
15.7k
Forks
5.6k
Avg merge
2d 44m
Merged PRs (30d)
80

Description

Description of Issue

With newer versions of pip3, pip.installed can only install to the default location.

Reason: Pip changed its behaviour.

Setup

Example from https://docs.saltproject.io/en/latest/ref/states/all/salt.states.pip_state.html :

django:
  pip.installed:
    - name: django
    - bin_env: /usr/bin/pip3
    - install_options:
      - --prefix=/blah
Steps to Reproduce Issue

Execute the aforementioned state. Obtain this error.

Versions Report

3001.7

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the salt.states.pip_state entry point and the pip.installed example in the issue, then reproduce the behavior using /usr/bin/pip3 with --prefix=/blah. Check how install_options are passed to newer pip versions. Done means pip.installed can install to the requested non-default location without the reported error.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
devops, infrastructure
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.