Really reinstall requests on Fedora

Clear out the meta-data provided by the rpm package, so pip does a
reinstall.  Fix for If3f244ed4f62da25dc42813b4bda2f374f002517

Change-Id: Ic3bd801c0f57a2453d3563aaa4cf778aa0a9f9bf
This commit is contained in:
Ian Wienand 2016-03-15 11:05:05 +11:00
parent f73fc067cb
commit 77568c6ee3

View File

@ -110,12 +110,13 @@ function setup_puppet_fedora {
# and then something like devstack does a "yum install
# python-requests" which does a very bad job at overwriting the
# pip-installed version (symlinks and existing directories don't
# mix). The solution is to pre-install the python-requests
# mix). A solution is to pre-install the python-requests
# package; clear it out and re-install from pip. This way, the
# package is installed for dependencies, and we have a pip-managed
# requests with correctly vendored sub-packages.
sudo ${YUM} install -y python-requests
sudo rm -rf /usr/lib/python2.7/site-packages/requests/*
sudo rm -rf /usr/lib/python2.7/site-packages/requests-*.{egg,dist}-info
sudo pip install requests
}