worlddump shouldn't depend on LOGDIR

Bug #1333321 reported by Steve Martinelli
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
devstack
Fix Released
Medium
Rick Harris

Bug Description

I saw the following when running devstack:

Requirement already up-to-date: pip in /usr/local/lib/python2.7/dist-packages
Cleaning up...
+ pip_install -U setuptools
++ set +o
++ grep xtrace
+ local 'xtrace=set -o xtrace'
+ set +o xtrace
+ sudo PIP_DOWNLOAD_CACHE=/var/cache/pip http_proxy= https_proxy= no_proxy= /usr/local/bin/pip install --build=/tmp/pip-build.es7Cf -U setuptools
Traceback (most recent call last):
  File "/usr/local/bin/pip", line 5, in <module>
    from pkg_resources import load_entry_point
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 2711, in <module>
    parse_requirements(__requires__), Environment()
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 584, in resolve
    raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: pip==1.4.1
++ err_trap
++ local r=1
++ set +o xtrace
stack.sh failed
Error on exit
usage: worlddump.py [-h] [-d DIR]
worlddump.py: error: argument -d/--dir: expected one argument

Although the error is related to pip versioning, the final result shows worlddump being executed incorrectly, since in the code it depends on $LOGDIR (which I'm guessing is setup after the requirements are figured out?)

    if [[ $r -ne 0 ]]; then
        echo "Error on exit"
        ./tools/worlddump.py -d $LOGDIR
    fi

Is there a way to move this check earlier? or make it not depend on $LOGDIR?

Revision history for this message
Dean Troyer (dtroyer) wrote :

stack.sh needs a bit of a reorg re ordering things like this...logging needs to be brought up much earlier.

Changed in devstack:
status: New → Triaged
importance: Undecided → Medium
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to devstack (master)

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

Changed in devstack:
assignee: nobody → Rick Harris (rconradharris)
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to devstack (master)

Reviewed: https://review.openstack.org/115066
Committed: https://git.openstack.org/cgit/openstack-dev/devstack/commit/?id=2696e5a0676c1ba39ee7f97b48ef65f5dc986d4f
Submitter: Jenkins
Branch: master

commit 2696e5a0676c1ba39ee7f97b48ef65f5dc986d4f
Author: Rick Harris <email address hidden>
Date: Mon Aug 18 13:53:42 2014 -0500

    Guard for worlddump in case LOGDIR is undefined

    If LOGDIR is undefined, we'll end up calling worldump with the `-d` option but
    pass in an empty string as the option value. This causes an argument parsing
    error inside worlddump.

    The proposed fix is to detect if LOGDIR is undefined, and if so, omit the `-d`
    argument.

    Change-Id: I77968849ebd3e3bebd2e5929b87b60fc1b6541bf
    Closes-Bug: 1333321

Changed in devstack:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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