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

Regression in 2.2.2 install, which removes all scripts in dist-packages/bin #2529

Closed
lionelnicolas opened this issue Oct 15, 2022 · 2 comments

Comments

@lionelnicolas
Copy link

lionelnicolas commented Oct 15, 2022

After upgrade to 2.2.2, all scripts in /usr/lib/python3/dist-packages/bin gets removed. Also, 2.2.2 installation ends with a warning:

WARNING: Target directory /tmp/regression/2.2.2/bin already exists. Specify --upgrade to force replacement

Reproducer:

#!/bin/sh

set -eu

# create workdir
mkdir -p /tmp/regression
cd /tmp/regression

# create new venv
python3 -m venv .venv
. .venv/bin/activate

# generate tiny requirements
cat >requirements.txt <<EOF
black==22.10.0
codespell==2.2.1
green==3.4.3
EOF

# install packages
pip3 install --no-cache-dir --requirement ./requirements.txt --ignore-installed --target /tmp/regression/2.2.1

# upgrade to 2.2.2
sed -i 's/codespell==2.2.1/codespell==2.2.2/' requirements.txt

# install packages in another directory
pip3 install --no-cache-dir --requirement ./requirements.txt --ignore-installed --target /tmp/regression/2.2.2

# list /bin directories
echo "=== 2.2.1 ==="
find /tmp/regression/2.2.1/bin/ -type f -ls
echo
echo "=== 2.2.2 ==="
find /tmp/regression/2.2.2/bin/ -type f -ls

In the output, you'll see that using 2.2.2, only codespell is present, black and green are not:

=== 2.2.1 ===
  1182243      4 -rwxr-xr-x   1 lionel   lionel        232 oct. 15 16:06 /tmp/regression/2.2.1/bin/coverage
  1182245      4 -rwxr-xr-x   1 lionel   lionel        232 oct. 15 16:06 /tmp/regression/2.2.1/bin/coverage3
  1182457      4 -rwxr-xr-x   1 lionel   lionel        967 oct. 15 16:06 /tmp/regression/2.2.1/bin/green3
  1182244      4 -rwxr-xr-x   1 lionel   lionel        232 oct. 15 16:06 /tmp/regression/2.2.1/bin/coverage-3.10
  1182581      4 -rwxr-xr-x   1 lionel   lionel        238 oct. 15 16:06 /tmp/regression/2.2.1/bin/blackd
  1182458      4 -rwxr-xr-x   1 lionel   lionel        973 oct. 15 16:06 /tmp/regression/2.2.1/bin/green3.10
  1182295      4 -rwxr-xr-x   1 lionel   lionel        245 oct. 15 16:06 /tmp/regression/2.2.1/bin/codespell
  1182580      4 -rwxr-xr-x   1 lionel   lionel        237 oct. 15 16:06 /tmp/regression/2.2.1/bin/black
  1182456      4 -rwxr-xr-x   1 lionel   lionel        965 oct. 15 16:06 /tmp/regression/2.2.1/bin/green
  1181877      4 -rwxr-xr-x   1 lionel   lionel        230 oct. 15 16:06 /tmp/regression/2.2.1/bin/unidecode

=== 2.2.2 ===
  1183347      4 -rwxr-xr-x   1 lionel   lionel        136 oct. 15 16:06 /tmp/regression/2.2.2/bin/codespell
@lionelnicolas
Copy link
Author

Could be related to this ? #2523

@DimitriPapadopoulos
Copy link
Collaborator

Yes, chances are #2523 is related.

Which exact Linux distribution is this? It looks like the pip and setuptools packages are broken/patched/different in Debian/Ubuntu. Does upgrading pip and setuptools help in any way?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants