Skip to content
This repository has been archived by the owner on Oct 18, 2024. It is now read-only.

Error during pip installation #234

Closed
T2L opened this issue Jan 27, 2021 · 2 comments · Fixed by #238
Closed

Error during pip installation #234

T2L opened this issue Jan 27, 2021 · 2 comments · Fixed by #238

Comments

@T2L
Copy link
Collaborator

T2L commented Jan 27, 2021

Vagrant assumes that this means the command failed!
curl https://bootstrap.pypa.io/get-pip.py | sudo python
Stdout from the command:
Stderr from the command:
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 1883k  100 1883k    0     0  3021k      0 --:--:-- --:--:-- --:--:-- 3022k
Traceback (most recent call last):
  File "<stdin>", line 24226, in <module>
  File "<stdin>", line 199, in main
  File "<stdin>", line 82, in bootstrap
  File "/tmp/tmp9wtDar/pip.zip/pip/_internal/cli/main.py", line 60
    sys.stderr.write(f"ERROR: {exc}")```
@T2L
Copy link
Collaborator Author

T2L commented Jan 27, 2021

So, PiP version 21+ requires Python 3.6+, which is not installed on Ubuntu 16.04 by default

@T2L
Copy link
Collaborator Author

T2L commented Jan 27, 2021

After digging into the issue here are the options:

A. Force PiP to use Python 3.5 by overriding pip_install_cmd for Ansible Local provisioner (see https://www.vagrantup.com/docs/provisioning/ansible_local#pip) - curl https://bootstrap.pypa.io/3.5/get-pip.py | sudo python

Drawbacks:

  • Python 3.5 is not supported anymore
  • it might not work for newer Ubuntu versions
  • this will lock the project with PiP 20.x.x

B. Install the latest (Python 3.9) on the machine and make it default

Drawbacks:

  • Python 3.9 does not include diskutils

    Debian has decided that diskutils is not a core python package, so it is not included in the last versions of Debian and Debian-based OSes.

  • python3-diskutils package is not available for Ubuntu 16.04

C. Install the still supported Python 3.7 on the machine and make it default
D. Let's migrate to Ubuntu 18.04 as the default (or maybe 20.04) #235

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

Successfully merging a pull request may close this issue.

1 participant