pip install pbr==0.5.22 fails unless run twice on ubuntu 12.04

Bug #1245676 reported by andrew plunk
60
This bug affects 9 people
Affects Status Importance Assigned to Milestone
OpenStack Heat
Fix Released
High
Nikhil Manchanda
PBR
Fix Released
Undecided
Nikhil Manchanda
python-pbr (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

1). ubuntu version:

lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 12.04.3 LTS
Release: 12.04
Codename: precise
---------------------------------------------------------------------

2). Package version:

pip install pbr==0.5.22
---------------------------------------------------------------------

3). Expected:

pip install pbr==0.5.22 succeeds in installing pbr version 0.5.22
---------------------------------------------------------------------

4). Acutal:

The first run fails, but consecutive executions of "pip install pbr==0.5.22" pass. Below is the output from the first run:

pip install -v pbr==0.5.22
Downloading/unpacking pbr==0.5.22
  Could not fetch URL http://pypi.python.org/simple/pbr/0.5.22: HTTP Error 404: Not Found (pbr/0.5.22)
  Will skip URL http://pypi.python.org/simple/pbr/0.5.22 when looking for download links for pbr==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.0.tar.gz#md5=957c5474720bd044b859d24c6fb5b1ca (from https://pypi.python.org/simple/pbr/), version 0.5.0 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.1.tar.gz#md5=ea4b32b03f606e4548adbdedd91b1bf2 (from https://pypi.python.org/simple/pbr/), version 0.5.1 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.10.tar.gz#md5=849a522f3b64b5a1c9c640d2fded4aa6 (from https://pypi.python.org/simple/pbr/), version 0.5.10 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.11.tar.gz#md5=56717ac59c8d4528742ab3f61a35fe6b (from https://pypi.python.org/simple/pbr/), version 0.5.11 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.12.tar.gz#md5=bc976fce6d07845eb69a2d9fcc3d176e (from https://pypi.python.org/simple/pbr/), version 0.5.12 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.13.tar.gz#md5=4c3a36aaa4c711728ab15186ddd2dc5a (from https://pypi.python.org/simple/pbr/), version 0.5.13 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.14.tar.gz#md5=b1462a461437b51286115bd5ab02b22b (from https://pypi.python.org/simple/pbr/), version 0.5.14 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.15.tar.gz#md5=f2ee400cc0f46bd074d16d7f6b1d63da (from https://pypi.python.org/simple/pbr/), version 0.5.15 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.16.tar.gz#md5=31c851aa6c16ba397e3b722234a8654d (from https://pypi.python.org/simple/pbr/), version 0.5.16 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.17.tar.gz#md5=ca5e8a790e230bc132cab98b31b8e39b (from https://pypi.python.org/simple/pbr/), version 0.5.17 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.18.tar.gz#md5=fd14abc6600fc63a87dd33268f2f6d19 (from https://pypi.python.org/simple/pbr/), version 0.5.18 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.19.tar.gz#md5=5e441e595b294e343ea3261aba6b7f76 (from https://pypi.python.org/simple/pbr/), version 0.5.19 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.2.5.g5b3e942.tar.gz#md5=276a1c4590ac231004a2d64a6887dc44 (from https://pypi.python.org/simple/pbr/), version 0.5.2.5.g5b3e942 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.2.tar.gz#md5=5f6e1870a2db8e35412acef33415c218 (from https://pypi.python.org/simple/pbr/), version 0.5.2 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.20.tar.gz#md5=bbfd338b8971084e6ef999f0b3b5a73a (from https://pypi.python.org/simple/pbr/), version 0.5.20 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.21.tar.gz#md5=1dafd1ef666b9bce4d880170ddc39387 (from https://pypi.python.org/simple/pbr/), version 0.5.21 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.4.tar.gz#md5=93c1a18af7d91c2bf470558dfa75a736 (from https://pypi.python.org/simple/pbr/), version 0.5.4 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.5.tar.gz#md5=8e5d90e3aa87cfd9b484f68283691376 (from https://pypi.python.org/simple/pbr/), version 0.5.5 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.6.tar.gz#md5=c34fad829c66a1cd0e55ab74908f5ce9 (from https://pypi.python.org/simple/pbr/), version 0.5.6 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.7.tar.gz#md5=d10fa77e985000f0f00c6af6a28acdb7 (from https://pypi.python.org/simple/pbr/), version 0.5.7 doesn't match ==0.5.22
  Ignoring link https://pypi.python.org/packages/source/p/pbr/pbr-0.5.8.tar.gz#md5=fa6a9330dc608ea53ae3ac1997fc9648 (from https://pypi.python.org/simple/pbr/), version 0.5.8 doesn't match ==0.5.22
  Downloading pbr-0.5.22.tar.gz (128Kb): 128Kb downloaded
  Running setup.py egg_info for package pbr
    running egg_info
    creating pip-egg-info/pbr.egg-info
    writing requirements to pip-egg-info/pbr.egg-info/requires.txt
    writing pip-egg-info/pbr.egg-info/PKG-INFO
    writing top-level names to pip-egg-info/pbr.egg-info/top_level.txt
    writing dependency_links to pip-egg-info/pbr.egg-info/dependency_links.txt
    writing entry points to pip-egg-info/pbr.egg-info/entry_points.txt
    [pbr] Processing SOURCES.txt
    writing manifest file 'pip-egg-info/pbr.egg-info/SOURCES.txt'
    warning: LocalManifestMaker: standard file '-c' not found

    error: No such file or directory
    Complete output from command python setup.py egg_info:
    running egg_info

creating pip-egg-info/pbr.egg-info

writing requirements to pip-egg-info/pbr.egg-info/requires.txt

writing pip-egg-info/pbr.egg-info/PKG-INFO

writing top-level names to pip-egg-info/pbr.egg-info/top_level.txt

writing dependency_links to pip-egg-info/pbr.egg-info/dependency_links.txt

writing entry points to pip-egg-info/pbr.egg-info/entry_points.txt

[pbr] Processing SOURCES.txt

writing manifest file 'pip-egg-info/pbr.egg-info/SOURCES.txt'

warning: LocalManifestMaker: standard file '-c' not found

error: No such file or directory

----------------------------------------
Command python setup.py egg_info failed with error code 1
Exception information:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 126, in main
    self.run(options, args)
  File "/usr/lib/python2.7/dist-packages/pip/commands/install.py", line 223, in run
    requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 980, in prepare_files
    req_to_install.run_egg_info()
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 216, in run_egg_info
    command_desc='python setup.py egg_info')
  File "/usr/lib/python2.7/dist-packages/pip/__init__.py", line 255, in call_subprocess
    % (command_desc, proc.returncode))
InstallationError: Command python setup.py egg_info failed with error code 1

Storing complete log in /root/.pip/pip.log

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in python-pbr (Ubuntu):
status: New → Confirmed
Revision history for this message
esala wona (esala-wangxiaoli) wrote :

how to resolve the problem which can not install keystone development environment?Thank you.

Denis M. (dmakogon)
Changed in pbr:
status: New → Confirmed
Revision history for this message
Mark Washenberger (markwash) wrote :

I run into a similar problem trying to install python-glanceclient in a virtualenv on 12.04.

As a workaround, pip install pbr==0.5.21 seems to make things work.

Revision history for this message
Carl George (carl.george) wrote :

I am having the same issue. I also tested on a few other distros.

These distros are affected:
Ubuntu 13.10
Debian 7

These distros are NOT affected:
Arch Linux
CentOS 6.4

Changed in pbr:
assignee: nobody → Nikhil Manchanda (slicknik)
Changed in python-pbr (Ubuntu):
assignee: nobody → Nikhil Manchanda (slicknik)
assignee: Nikhil Manchanda (slicknik) → nobody
Revision history for this message
Nikhil Manchanda (slicknik) wrote :

I debugged this some more, and the issue seems to be that pbr fails to install if git is not already installed on the instance.
I'm working on a fix. Stay posted.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to pbr (master)

Fix proposed to branch: master
Review: https://review.openstack.org/54510

Changed in pbr:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to pbr (master)

Reviewed: https://review.openstack.org/54510
Committed: http://github.com/openstack-dev/pbr/commit/629bbce1c88a4a576182c7a41372a70a864d8226
Submitter: Jenkins
Branch: master

commit 629bbce1c88a4a576182c7a41372a70a864d8226
Author: Nikhil Manchanda <email address hidden>
Date: Wed Oct 30 03:08:48 2013 -0700

    Fixed pbr install to not error out and fail if git is not installed

    Fixed the issue where pbr was erroring out (file not found) when
    running 'python setup.py egg_info' since it was trying to get the
    .git directory even if git was not installed.

    Closes bug 1245676

    Change-Id: I31e1f86f10f18897774b49eb293aede31641db31

Changed in pbr:
status: In Progress → Fix Committed
Revision history for this message
Clint Byrum (clint-fewbar) wrote :

Have not yet tested if 0.5.23 fixes the issues that have been reported in Heat's resources, will close this if 0.5.23 addresses it.

Changed in heat:
status: New → Triaged
importance: Undecided → Critical
Revision history for this message
andrew plunk (andrew-plunk) wrote :

pbr 0.5.23 works for me in ubuntu 12.04, thanks everyone!

-----------------------------------------------------------------------------------
pip install pbr==0.5.23
Downloading/unpacking pbr==0.5.23
  Downloading pbr-0.5.23.tar.gz (128Kb): 128Kb downloaded
  Running setup.py egg_info for package pbr
    [pbr] Processing SOURCES.txt
    warning: LocalManifestMaker: standard file '-c' not found

    warning: no previously-included files found matching '.gitignore'
    warning: no previously-included files found matching '.gitreview'
    warning: no previously-included files matching '*.pyc' found anywhere in distribution
    warning: no previously-included files found matching '.gitignore'
    warning: no previously-included files found matching '.gitreview'
    warning: no previously-included files matching '*.pyc' found anywhere in distribution
Requirement already satisfied (use --upgrade to upgrade): pip>=1.0 in /usr/lib/python2.7/dist-packages (from pbr==0.5.23)
Installing collected packages: pbr
  Running setup.py install for pbr
    [pbr] Reusing existing SOURCES.txt
Successfully installed pbr
Cleaning up...

Changed in heat:
importance: Critical → High
Revision history for this message
Nikhil Manchanda (slicknik) wrote :

The fix in pbr should have fixed this for heat as well (heat-cfntools install was failing because of a failure in the pbr install which is a dependency)

Changed in heat:
assignee: nobody → Nikhil Manchanda (slicknik)
status: Triaged → Fix Committed
Revision history for this message
Nikhil Manchanda (slicknik) wrote :

Tested that an install of heat-cfntools succeeds with the new 0.5.23 release.

Revision history for this message
Clint Byrum (clint-fewbar) wrote : Re: [Bug 1245676] Re: pip install pbr==0.5.22 fails unless run twice on ubuntu 12.04

This would suggest that we need to set pbr>=0.5.23 in requirements for
heat-cfntools. It would only affect those who are installing them in a
system or venv that already has >= 0.5.16 (the current req), so it is
still a low priority.

Chuck Short (zulcss)
Changed in python-pbr (Ubuntu):
status: Confirmed → Fix Released
Thierry Carrez (ttx)
Changed in heat:
milestone: none → icehouse-1
status: Fix Committed → Fix Released
Revision history for this message
anatoly techtonik (techtonik) wrote :
Thierry Carrez (ttx)
Changed in heat:
milestone: icehouse-1 → 2014.1
Changed in pbr:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

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