Comment 4 for bug 1782051

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to openstack-ansible-pip_install (stable/queens)

Reviewed: https://review.openstack.org/583925
Committed: https://git.openstack.org/cgit/openstack/openstack-ansible-pip_install/commit/?id=aa74bf466e10bb41702d1187ca7779dd242e5145
Submitter: Zuul
Branch: stable/queens

commit aa74bf466e10bb41702d1187ca7779dd242e5145
Author: Jean-Philippe Evrard <email address hidden>
Date: Thu Jul 19 12:50:03 2018 +0200

    Ensure get-pip is not used when good version of pip is present

    This is a combined backport of three commits to make sure
    get-pip will be skipped if an appropriate version of pip is
    present.

    By skipping get-pip, no downgrade of pip will happen on the
    hosts, leading to issues like the bug here.

    Here are the commits:
    tests: Do not always fetch the get-pip.py script during tests

    Since we are testing the idempotence of this role, we shouldn't
    fetch the get-pip.py script on every iteration so we set the variable
    to 'false'. Moreover, we bump the PIP version to 9.0.3 since this is
    what is currently being deployed on the hosts. Finally, get-pip.py
    uses --force-reinstall by default which means that everything is being
    reinstalled all the time and this breaks idempotence. We can fix that by
    simply checking if a suitable version of PIP is installed and then use
    it to do a proper upgrade.

    ---

    tasks: main: Fix conditional for PIP script

    The conditional must search the 'stdout' item to find the string we
    are looking for.

    ---

    Ensure the fallback uses the same install method

    We have a test to ensure the install method of pip is from distro
    or get-pip. But if an issue appeared in the first task, the
    fallback method will automatically fallback to get-pip instead
    of fallback to the isolated version of the pre-defined CLI.

    This should ensure consistency by not using get-pip if it's not
    needed.

    ---

    (cherry picked from commit 40373daf7e27ab8cef00611945acf68c3e86fe82)
    (cherry picked from commit fe5d99228bb756a28fb433b4a734d1e604eb0482)
    (cherry picked from commit b6024a918442c0f89e207e496f497d14a8d55ba1)

    Change-Id: Ia6efeb278fd7a7ec32b9a48c8b3e44197afe182c
    Related-Bug: 1782051
    Related-Bug: 1779534