Description
On Windows, it turns out pyperf (and hence pyperformance) will always print a warning when psutil is not installed. The warning is:
WARNING: unable to increase process priority
It is printed by _process_priority()
. (Note the if not MS_WINDOWS: return
right before.)
The function set_priority()
silently returns None
, but the caller prints the warning in that case.
So now for every benchmark run by pyperformance it calls this _process_priority()
function for each run, printing the warning each time (maybe 10 times per run).
The solution of course is to install psutil. But no matter what I do, because the way venvs used to run the benchmark are created, those venvs do not get psutil installed, even if it is installed in site-packages. (At least, when running from a dev environment.)
- I tried adding
"psutil"
to theinstall_requires
line in pyperformance's setup.py, but that doesn't seem to help. - psutil is already listed in requirements.in, so that doesn't seem to make a difference.
- It is also listed in pyperformance/data-files/requirements.txt, apparently with no effect.
So how do I add this dependency to every package? Surely there's a more elegant way than adding it to every benchmark-specific requirements.txt file in pyperformance/data-files/benchmarks?