ERROR -- Can not grab extended stats (invalid attr name 'num_fds') #1351

This commit is contained in:
nicolargo 2018-11-18 21:23:13 +01:00
parent e1e5af5c1c
commit dda9dd3b8f
2 changed files with 5 additions and 1 deletions

1
NEWS
View File

@ -17,6 +17,7 @@ Bugs corrected:
* Crash after running fine for several hours #1335
* Timezone listed doesnt match system timezone, outputs wrong time #1337
* Compare issue with Process.cpu_times() #1339
* ERROR -- Can not grab extended stats (invalid attr name 'num_fds') #1351
Others:

View File

@ -279,7 +279,10 @@ class GlancesProcesses(object):
try:
top_process = psutil.Process(proc['pid'])
extended_stats = ['cpu_affinity', 'ionice',
'num_ctx_switches', 'num_fds']
'num_ctx_switches']
if LINUX:
# num_fds only avalable on Unix system (see issue #1351)
extended_stats += ['num_fds']
if WINDOWS:
extended_stats += ['num_handles']