salt icon indicating copy to clipboard operation
salt copied to clipboard

ps.top: psutils.cpu_times() return changed

Open aleksmm opened this issue 10 years ago • 2 comments

psutils package changed return tuple adding two more values leading to exception for packages versions >=4.1.0 Return a (user, system, children_user, children_system) namedtuple

psutils.cpu_times() Changed in version 4.1.0: return two extra fields: children_user and children_system.

Setup

salt/modules/ps.py

File "/usr/lib/python2.6/site-packages/salt/modules/ps.py", line 132, in top user, system = process.cpu_times() ValueError: too many values to unpack

Steps to Reproduce Issue

salt-call ps.top

Versions Report

I checked this line in develop branch and it still unpacks into two values

aleksmm avatar Jul 07 '16 12:07 aleksmm

@aleksmm I believe this is a duplicate of #34170 . Looks like there is a fix in at #32182. Would you mind giving that fix a try?

Ch3LL avatar Jul 07 '16 18:07 Ch3LL

yes, obviously the fix will work. I was trying to find the ticket to avoid creating duplicate. Sorry.

aleksmm avatar Jul 13 '16 07:07 aleksmm