LIwianwpIO / psymon

Automatically exported from code.google.com/p/psymon
0 stars 0 forks source link

psutil.cpu_times() works differently on OS X than it does on Linux #2

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
I got the following exception in OS X:

AttributeError: 'cputimes' object has no attribute 'iowait'

That is because CpuStat.__lookup() does only distinguish between Windows and 
POSIX. However psutil.cpu_times() returns more values under Linux than it does 
under OS X resulting in the exception above.

I attached a patch to fix the problem.

Original issue reported on code.google.com by gestat...@gmail.com on 23 Aug 2012 at 5:43

GoogleCodeExporter commented 8 years ago
Thanks for the fix!

Original comment by kotsifi on 6 Sep 2012 at 12:59