Glance Tests Will Fail With psutil 2.0.0

Bug #1298039 reported by Solly Ross
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Glance
Fix Released
Undecided
Unassigned

Bug Description

psutil recently released a new version in which the majorly broke API backwards-compatibility. Currently, the requirement for psutil is 'psutil>=1.1.1'. We should limit the psutil version to 'psutil>=1.1.1,<2.0.0' so as to not break the multiprocessing tests, which use psutil.

Thierry Carrez (ttx)
Changed in glance:
milestone: none → icehouse-rc1
Revision history for this message
Zhi Yan Liu (lzy-dev) wrote :

I can't reproduce situation you mentioned in my local development environment. Please provide more information, like log, exception stack and etc.

lzy@dev-controller-master:~/workspace/openstack-org/glance$ tools/with_venv.sh python
Python 2.7.3 (default, Feb 27 2014, 19:58:35)
[GCC 4.6.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import psutil
>>> psutil.__file__
'/home/lzy/workspace/openstack-org/glance/.venv/local/lib/python2.7/site-packages/psutil/__init__.pyc'
>>> import pkg_resources
>>> pkg_resources.get_distribution("psutil").version
'2.0.0'
>>> exit()

lzy@dev-controller-master:~/workspace/openstack-org/glance$ ./run_tests.sh glance.tests.functional.v1.test_multiprocessing
Running `tools/with_venv.sh python -m glance.openstack.common.lockutils python setup.py testr --testr-args='--subunit --concurrency 1 glance.tests.functional.v1.test_multiprocessing'`
glance.tests.functional.v1.test_multiprocessing.TestMultiprocessing
    test_interrupt_avoids_respawn_storm OK 5.14
    test_multiprocessing OK 2.27

Slowest 2 tests took 7.41 secs:
glance.tests.functional.v1.test_multiprocessing.TestMultiprocessing
    test_interrupt_avoids_respawn_storm 5.14
    test_multiprocessing 2.27

Ran 2 tests in 10.933s

OK

Revision history for this message
Solly Ross (sross-7) wrote :

It would appear that the author left some of the old methods in place as deprecated versions without actually documenting that, while others he just removed. It would appear the ones that glance uses are still in place in 2.0.0, although there's no indication as to when that will change (especially since they no longer appear in the documentation). Sorry about any confusion there (I could have sworn the same method broke in similar code I had elsewhere...).

Changed in glance:
status: New → Invalid
status: Invalid → New
Revision history for this message
Solly Ross (sross-7) wrote :

I still think it's important to limit psutil to <2.0.0 -- we shouldn't be using undocumented methods that have no indication as to when they will disappear

Thierry Carrez (ttx)
Changed in glance:
milestone: icehouse-rc1 → none
Revision history for this message
Erno Kuvaja (jokke) wrote :

Proposed fix Merged 35b806893401ea1e0fca29a2f51470df590af52d

Changed in glance:
status: New → Fix Committed
Changed in glance:
milestone: none → juno-2
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in glance:
milestone: juno-2 → 2014.2
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.