Skip to content

Instantly share code, notes, and snippets.

@mohanpedala
Last active April 29, 2019 18:05
Show Gist options
  • Save mohanpedala/36247a2626131932d68cacadb1d73bc5 to your computer and use it in GitHub Desktop.
Save mohanpedala/36247a2626131932d68cacadb1d73bc5 to your computer and use it in GitHub Desktop.
python pip ssl issue while installing requirements and boto3 installation for python3
  • You can ignore SSL errors by setting pypi.org and files.pythonhosted.org as trusted hosts.
pip install --trusted-host pypi.org --trusted-host files.pythonhosted.org <package_name>

Note: Sometime during April 2018, the Python Package Index was migrated from pypi.python.org to pypi.org. This means "trusted-host" commands using the old domain no longer work.

  • Permanent Fix: You may want to add the trusted hosts and proxy to your config file.
mkdir -p ~/.config/pip
vi ~/.config/pip/pip.conf
[global]
trusted-host = pypi.python.org
               pypi.org
               files.pythonhosted.org
  • Install boto3
python3 -m pip install boto3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment