Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | adjust flake8memleak-fluctuation | Giampaolo Rodola | 2020-05-12 | 2 | -12/+17 |
| | |||||
* | fun full times | Giampaolo Rodola | 2020-05-10 | 1 | -3/+2 |
| | |||||
* | adjust logic | Giampaolo Rodola | 2020-05-10 | 1 | -28/+21 |
| | |||||
* | disable gc | Giampaolo Rodola | 2020-05-09 | 1 | -32/+24 |
| | |||||
* | progress | Giampaolo Rodola | 2020-05-09 | 2 | -7/+13 |
| | |||||
* | implement fluctuation logic | Giampaolo Rodola | 2020-05-07 | 2 | -38/+28 |
| | |||||
* | Add new TestFdsLeak test class (#1752) | Giampaolo Rodola | 2020-05-06 | 7 | -66/+162 |
| | |||||
* | Windows: refactor proc username(), split it in 2 functions | Giampaolo Rodola | 2020-05-05 | 2 | -54/+59 |
| | |||||
* | fix some memleak tests on win | Giampaolo Rodola | 2020-05-05 | 4 | -9/+29 |
| | |||||
* | have mem leak test class check num of fds/handles | Giampaolo Rodola | 2020-05-04 | 3 | -47/+43 |
| | |||||
* | Merge branch 'master' of github.com:giampaolo/psutil | Giampaolo Rodola | 2020-05-04 | 8 | -285/+419 |
|\ | |||||
| * | Refactor tests calling all process methods (process_namespace class) (#1749) | Giampaolo Rodola | 2020-05-04 | 9 | -299/+430 |
| | | | | | | Over the years I have accumulated different unit-tests which use dir() to get all process methods and test them in different circumstances. This produced a lot of code duplication. With this PR I introduce 2 new test classes (process_namespace and system_namespace) which declare all the method names and arguments in a single place, removing a lot cruft and code duplication. | ||||
* | | update README | Giampaolo Rodola | 2020-05-03 | 1 | -14/+11 |
|/ | |||||
* | Process wait() improvements (#1747) | Giampaolo Rodola | 2020-05-03 | 12 | -159/+306 |
| | | | | | | | | | | | | | | | | | | | | | | * `Process.wait()` on POSIX now returns an `enum` showing the negative which was used to terminate the process: ```python >>> import psutil >>> p = psutil.Process(9891) >>> p.terminate() >>> p.wait() <Negsignal.SIGTERM: -15> ``` * the return value is cached so that the exit code can be retrieved on then next call, mimicking `subprocess.Popen.wait()` * `Process` object provides more `status` and `exitcode` additional info on `str()` and `repr()`: ``` >>> proc psutil.Process(pid=12739, name='python3', status='terminated', exitcode=<Negsigs.SIGTERM: -15>, started='15:08:20') ``` Extra: * improved `wait()` doc * reverted #1736: `psutil.Popen` uses original `subprocess.Popen.wait` method (safer) | ||||
* | Parallelize fetch all processes tests with proc pool (#1746) | Giampaolo Rodola | 2020-05-02 | 1 | -114/+103 |
| | | | | | | | | | | | | | | | | | | | | | | | | Despite I recently implemented parallel tests on UNIX (#1709), TestFetchAllProcesses class is the slowest one to run because it gets all possible info for all processes in one go. In fact it's a singe unit-test, so it's not parallelized by the test runner. In here I used multiprocessing.Pool to do the trick. On my main linux box (8 cores): Before: ---------------------------------------------------------------------- Ran 1 test in 2.511s After: ---------------------------------------------------------------------- Ran 1 test in 0.931s On Windows (virtualized, 4 cores): Before: ---------------------------------------------------------------------- Ran 1 test in 13.752s After: ---------------------------------------------------------------------- Ran 1 test in 3.951s | ||||
* | cleanup psutil mod namespace a bit | Giampaolo Rodola | 2020-05-01 | 1 | -21/+18 |
| | |||||
* | refactor signal tests | Giampaolo Rodola | 2020-05-01 | 1 | -50/+38 |
| | |||||
* | fix AttributeError | Giampaolo Rodola | 2020-05-01 | 1 | -2/+8 |
| | |||||
* | Refactor process test utils methods (#1745) | Giampaolo Rodola | 2020-05-01 | 11 | -178/+151 |
| | | | ...in order to accomodate Cygwin implementation. | ||||
* | Drastically improve "make test/build" speed. | Giampaolo Rodola | 2020-05-01 | 4 | -39/+39 |
| | | | | | | | Doing "make install" before any test is slow and not really necessary. Instead do "make build", and remove the part import setuptools and test psutil can be imported (do that in make install instead). This way I went down from 0.8 secs (install phase before starting the test) to 0.3 secs! | ||||
* | Revert #1736: Popen inheriting from subprocess (#1744) | Giampaolo Rodola | 2020-05-01 | 5 | -112/+69 |
| | |||||
* | Per-test file cleanup and new PsutilTestCase (#1743) | Giampaolo Rodola | 2020-04-30 | 18 | -269/+262 |
| | | | | | Test files/dirs are now removed after each test. when invoked via self.get_testfn(). Until now test files were stored in a global variable and were removed at process exit, via atexit.register(), but this didn't work with parallel tests because the fork()ed workers use os._exit(0), preventing cleanup functions to run. All test classes now inherit from PsutilTestCase class, which provides the most important methods requiring an automatic cleanup (get_test_subprocess() and others). | ||||
* | Merge branch 'test-runner-refact' | Giampaolo Rodola | 2020-04-30 | 3 | -151/+159 |
|\ | |||||
| * | See: #1709: allow per-test parallelization | Giampaolo Rodola | 2020-04-30 | 8 | -170/+187 |
| | | | | | | | | | | | | | | | | Refactor test runner.py with a saner unittest-based class hierarchy so that --parallel args affects all test suites (all, by-name, failed). Also change Makefile which now can be used like this: make test-process ARGS=--parallel | ||||
* | | Parallel build (#1741) | Giampaolo Rodola | 2020-04-30 | 6 | -19/+28 |
|/ | |||||
* | refactoring / rename vars | Giampaolo Rodola | 2020-04-29 | 1 | -12/+10 |
| | |||||
* | Test sub-processes cleanup and ProcessTestCase class (#1739) | Giampaolo Rodola | 2020-04-28 | 12 | -215/+260 |
| | |||||
* | show status() in __repr__ | Giampaolo Rodola | 2020-04-28 | 3 | -20/+24 |
| | |||||
* | create_zombie_proc() make it return parent so that we can kill zombie | Giampaolo Rodola | 2020-04-28 | 4 | -19/+27 |
| | |||||
* | psutil.Popen: inherit from subprocess + support wait(timeout=...) parameter ↵ | Giampaolo Rodola | 2020-04-28 | 8 | -60/+99 |
| | | | | (#1736) | ||||
* | add new termina() test util | Giampaolo Rodola | 2020-04-27 | 1 | -56/+73 |
| | |||||
* | Merge branch 'master' into devreap-children | Giampaolo Rodola | 2020-04-26 | 25 | -134/+315 |
|\ | |||||
| * | Parallel tests (UNIX) (#1709) | Giampaolo Rodola | 2020-04-26 | 25 | -134/+315 |
| | | |||||
* | | rename var | Giampaolo Rodola | 2020-04-26 | 5 | -45/+45 |
|/ | |||||
* | trick to execute atexit functions in case of SIGTERM | Giampaolo Rodola | 2020-04-25 | 1 | -21/+34 |
| | |||||
* | Merge branch 'master' of github.com:giampaolo/psutil | Giampaolo Rodola | 2020-04-24 | 10 | -355/+300 |
|\ | |||||
| * | Get rid of TESTFN global variable (#1734) | Giampaolo Rodola | 2020-04-24 | 10 | -355/+300 |
| | | |||||
* | | Merge branch 'master' of github.com:giampaolo/psutil | Giampaolo Rodola | 2020-04-24 | 6 | -30/+111 |
|\ \ | |/ | |||||
| * | Backport python 3 super() (#1733) | Giampaolo Rodola | 2020-04-24 | 7 | -34/+112 |
| | | |||||
* | | skip scripts test if can't locate directory | Giampaolo Rodola | 2020-04-24 | 1 | -4/+1 |
|/ | | | | | May happen on CI and when running tests via "python -m psutil.tests" since scripts dir is not installed. | ||||
* | Merge branch 'master' of github.com:giampaolo/psutil | Giampaolo Rodola | 2020-04-23 | 12 | -443/+572 |
|\ | |||||
| * | MemoryLeakTest class enhancements (#1731) | Giampaolo Rodola | 2020-04-23 | 13 | -442/+586 |
| | | |||||
| * | Remove useless assignment (#1728) | kaiix | 2020-04-16 | 1 | -1/+0 |
| | | |||||
* | | Merge branch 'master' of github.com:giampaolo/psutil | Giampaolo Rodola | 2020-04-15 | 4 | -4/+4 |
|\ \ | |/ | |||||
| * | Fix handling /proc/cpuinfo without tabs (#1726) | Michał Górny | 2020-04-14 | 1 | -1/+1 |
| | | | | | | | | | | | | | | /proc/cpuinfo uses spaces rather than tabs on ia64. Since there seems not to be any reason to require specific kind of whitespace before ':' on 'cpu mhz' line, just split on ':'. See: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/ia64/kernel/setup.c#n700 | ||||
| * | Fixup release date (#1716) | Andrey Babak | 2020-03-14 | 1 | -1/+1 |
| | | |||||
| * | sensors_fans is not available on MacOS (#1710) | crusaderky | 2020-03-04 | 2 | -2/+2 |
| | | |||||
* | | update HISTORY/CREDITS | Giampaolo Rodola | 2020-04-14 | 2 | -0/+14 |
|/ | |||||
* | Fix detecting empty result in TestSystemAPIs.test_users() (#1699) | Michał Górny | 2020-02-21 | 1 | -2/+2 |
| | |||||
* | Git hook for renamed/added/deleted files + flake8 print() + tidelift (#1704) | Giampaolo Rodola | 2020-02-21 | 16 | -173/+230 |
| |