Skip to content

Commit

Permalink
bugfix: this can be func or data attr depends on psutil ver
Browse files Browse the repository at this point in the history
  • Loading branch information
hvnsweeting committed Jan 15, 2015
1 parent 7a772d7 commit 023895b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/collectors/processresources/processresources.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ def collect_process_info(self, process):
pi = process_info(process, self.default_info_keys)
if cfg['count_workers']:
pi.update({'workers_count': 1})
uptime = time.time() - getattr(process, 'create_time')
uptime = time.time() - get_value(process, 'create_time')
pi.update({'uptime': uptime})
self.save_process_info(pg_name, pi)
except psutil.NoSuchProcess, e:
Expand Down

0 comments on commit 023895b

Please sign in to comment.