Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

psutil has no attribute cpu_stats #794

Closed
MichaelCurrie opened this issue Mar 6, 2016 · 1 comment
Closed

psutil has no attribute cpu_stats #794

MichaelCurrie opened this issue Mar 6, 2016 · 1 comment

Comments

@MichaelCurrie
Copy link

>>> import psutil
>>> psutil.cpu_stats()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: module 'psutil' has no attribute 'cpu_stats'

However it is shown as an example on the main page:

>> psutil.cpu_stats()
scpustats(ctx_switches=20455687, interrupts=6598984, soft_interrupts=2134212)

I'm running

>>> import sys
>>> sys.version
'3.5.1 |Continuum Analytics, Inc.| (default, Dec  7 2015, 11:16:01) \n[GCC 4.4.7 20120313 (Red Hat 4.4.7-1)]'
>>> psutil.__version__
'4.0.0'

on

$ uname -a
Linux ip-172-31-9-94 3.13.0-79-generic #123-Ubuntu SMP Fri Feb 19 14:27:58 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
@MichaelCurrie MichaelCurrie changed the title psutil.cpu_stats() does not work psutil has no attribute cpu_stats Mar 6, 2016
@giampaolo
Copy link
Owner

Hehe, that's because it's a feature I developed (see ##792) but I still have to package a new psutil release/tarball, so technically it's not available yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants