installed pip version 1 does not meet minimum requirements

Bug #1764046 reported by bing lee
26
This bug affects 5 people
Affects Status Importance Assigned to Milestone
devstack
Fix Released
Undecided
Elod Illes

Bug Description

Description:
[ERROR] /opt/stack/devstack/inc/python:146 Currently installed pip version 1 does not meet minimum requirements (>=6).

Reason:
The code in '/opt/stack/devstack/inc/python' line 142 to 148

 local pip_version
    pip_version=$(python -c "import pip; \
                        print(pip.__version__.strip('.')[0])")
    if (( pip_version<6 )); then
        die $LINENO "Currently installed pip version ${pip_version} does not" \
            "meet minimum requirements (>=6)."
    fi

When the pip version >10, the resule of 'pip.__version__.strip('.')[0]' is 1, then the error happen.

Fix method:

The code should be:

local pip_version
    pip_version=$(python -c "import pip; \
                        print(pip.__version__.split('.')[0])")
    if (( pip_version<6 )); then
        die $LINENO "Currently installed pip version ${pip_version} does not" \
            "meet minimum requirements (>=6)."
    fi

Revision history for this message
Elod Illes (elod-illes) wrote :

Affects stable/pike and stable/ocata only, the newer releases contain the fix

Changed in devstack:
assignee: nobody → Illes Elod (elod-illes)
Revision history for this message
Elod Illes (elod-illes) wrote :
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to devstack (stable/ocata)

Reviewed: https://review.openstack.org/561416
Committed: https://git.openstack.org/cgit/openstack-dev/devstack/commit/?id=b376719fc0b1ce225a564c0d32091b53db408f6d
Submitter: Zuul
Branch: stable/ocata

commit b376719fc0b1ce225a564c0d32091b53db408f6d
Author: Clark Boylan <email address hidden>
Date: Fri Oct 20 12:14:29 2017 -0700

    Properly get pip version

    The old code was strip()ing the version string instead of split()ing the
    version string so we always got the first character of the version
    string. This worked fine as long as the pip version was single digit but
    as soon as it rolls over to '10.stuff' we will compare:

      pip version 1 (instead of 10) > 6

    Which fails bceause 1 is less than six. Instaed we really do want to
    compare 10 > 6 so use split on '.' instead.

    Closes-Bug: #1764046
    Change-Id: Ic7d0c04d7fa77774ab2d70fb9d11f182becec553
    (cherry picked from commit 065779517f9c99a80fbc39d51784c614e4ee341c)

tags: added: in-stable-ocata
bing lee (binglee33)
Changed in devstack:
status: New → Fix Committed
status: Fix Committed → Confirmed
status: Confirmed → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to devstack (stable/pike)

Reviewed: https://review.openstack.org/561411
Committed: https://git.openstack.org/cgit/openstack-dev/devstack/commit/?id=91d6d0f932097d0436e43f34623ee484c9edecc7
Submitter: Zuul
Branch: stable/pike

commit 91d6d0f932097d0436e43f34623ee484c9edecc7
Author: Clark Boylan <email address hidden>
Date: Fri Oct 20 12:14:29 2017 -0700

    Properly get pip version

    The old code was strip()ing the version string instead of split()ing the
    version string so we always got the first character of the version
    string. This worked fine as long as the pip version was single digit but
    as soon as it rolls over to '10.stuff' we will compare:

      pip version 1 (instead of 10) > 6

    Which fails bceause 1 is less than six. Instaed we really do want to
    compare 10 > 6 so use split on '.' instead.

    Closes-Bug: #1764046
    Change-Id: Ic7d0c04d7fa77774ab2d70fb9d11f182becec553
    (cherry picked from commit 065779517f9c99a80fbc39d51784c614e4ee341c)

tags: added: in-stable-pike
Revision history for this message
Guiu (guiu) wrote :

That also affects to stable/newton branch.

Thank you!

tags: added: in-stable-newton
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to devstack (stable/newton)

Fix proposed to branch: stable/newton
Review: https://review.openstack.org/562610

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on devstack (stable/newton)

Change abandoned by Matt Riedemann (<email address hidden>) on branch: stable/newton
Review: https://review.openstack.org/562610

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Change abandoned by Paweł Suder (<email address hidden>) on branch: stable/newton
Review: https://review.openstack.org/640985
Reason: Ok, got it, closing it, thank you!

Revision history for this message
ydemiral (yasemin-demiral) wrote :

stable/newton version is affected the bug

Revision history for this message
ydemiral (yasemin-demiral) wrote :
Revision history for this message
Dr. Jens Harbott (j-harbott) wrote :

As mentioned in the review, the stable/newton branch is EOL for over a year now, you should use a more current branch.

Revision history for this message
Elod Illes (elod-illes) wrote :

Hi Yasemin,

stable/newton reached it's End of Life and patches are not merged there anymore [1].
I suggest to use newer version of OpenStack / devstack. The recent stable version is stable/stein.

[1] https://releases.openstack.org/

Thanks,

Előd

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.