Closed GoogleCodeExporter closed 8 years ago
I originally added this feature as a private method for testing purposes:
http://code.google.com/p/psutil/source/detail?r=979#
...then removed it because the test was not reliable:
http://code.google.com/p/psutil/source/detail?r=1056
I wasn't sure whether it would have been useful (that's why it was private).
Out of curiosity: what do you need this for?
Original comment by g.rodola
on 19 Aug 2011 at 6:24
I am a QA. I've used it for monitor resources leaks. Handles count leaks are
very important for my customer. Currently this only one feature that I use not
from psutil.
In any case, thanks for your work.
Original comment by moden4dr...@gmail.com
on 11 Sep 2011 at 6:40
Original comment by g.rodola
on 22 Oct 2011 at 11:45
Windows uses handles for references to operating system objects. Objects like
threads, files, and sockets all get handles.
Being able to keep a handle count in windows can be vital as a reported
statistic under windows. There are many places in windows software where a
handle leak can be used to identify a file that wasn't closed, or a socket that
wasnt cleaned up properly, etc. Using these numbers a programmer can then look
at the currently opened handles using a tool like process explorer to track
down what type of object is leaking and fix the problem.
The only request I would make for the old code is changing "handlers" to
"handles".
Original comment by david.da...@gmail.com
on 31 Oct 2011 at 3:44
This is now committed in r1291.
As for my previous comment:
> [...] I removed it because the test was not reliable
I think the test was not accurate. I rewrote it here:
http://code.google.com/p/psutil/source/browse/trunk/test/_windows.py?spec=svn129
1&r=1291#218
...and it seems to work now.
Very sporadically it fails but I suppose that's because Windows might need
sometime to actually close the process handle.
Original comment by g.rodola
on 21 Apr 2012 at 5:56
0.5.0 is finally out. Closing out as fixed.
Original comment by g.rodola
on 27 Jun 2012 at 6:54
[deleted comment]
Updated csets after the SVN -> Mercurial migration:
r1291 == revision d37b3525b133
Original comment by g.rodola
on 2 Mar 2013 at 12:02
Original issue reported on code.google.com by
moden4dr...@gmail.com
on 11 Aug 2011 at 10:40