Closed justinxzhao closed 2 years ago
Hello
Thanks for submitting! I think psutil is not able to handle CPU frequency on Apple M1. As I just get a brand new laptop, I'll check this intuition and strive to provide a fix quickly. :)
Thanks @js-dieu! Congrats on your new laptop. Hopefully it's not a complicated fix.
@justinxzhao
Seems not complex. However, psutil has released a version with support for M1 chipset. Can you please give me the output of the following (to be run in your environment):
import memory_profiler as mp
import psutil as ps
print(ps.__version__)
print(mp.__version__)
It's strange that pip does not manage to give you the latest version of psutil .
@js-dieu
Here's my output:
>>> import memory_profiler as mp
import psutil as ps
print(ps.__version__)
print(mp.__version__)
>>> import psutil as ps
>>>
>>> print(ps.__version__)
5.9.1
>>> print(mp.__version__)
0.60.0
@justinxzhao
Ok, that means that psutil support of M1 is still partial. I am afraid we have to wait for them to fix this issue.
Hello @justinxzhao
I think that the latest release (1.6.5) should fix your issue. It is a fallback though, thus imperfect, but enough for you to run with pytest-monitor
. Waiting for psutil
to fix it completely though.
Do not hesitate to reopen if encounter another psutil related issue with pytest-monitor-1.6.5
After installing pytest-monitor, and running pytest, I get an error:
Stack trace:
Desktop: