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

Update psutil to 5.7.0 #95

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

pyup-bot
Copy link

This PR updates psutil from 2.2.1 to 5.7.0.

Changelog

5.7.0

=====

2020-12-18

**Enhancements**

- 1637_: [SunOS] add partial support for old SunOS 5.10 Update 0 to 3.
- 1648_: [Linux] sensors_temperatures() looks into an additional /sys/device/
directory for additional data.  (patch by Javad Karabi)
- 1652_: [Windows] dropped support for Windows XP and Windows Server 2003.
Minimum supported Windows version now is Windows Vista.
- 1671_: [FreeBSD] add CI testing/service for FreeBSD (Cirrus CI).
- 1677_: [Windows] process exe() will succeed for all process PIDs (instead of
raising AccessDenied).
- 1679_: [Windows] net_connections() and Process.connections() are 10% faster.
- 1682_: [PyPy] added CI / test integration for PyPy via Travis.
- 1686_: [Windows] added support for PyPy on Windows.
- 1693_: [Windows] boot_time(), Process.create_time() and users()'s login time
now have 1 micro second precision (before the precision was of 1 second).

**Bug fixes**

- 1538_: [NetBSD] process cwd() may return ENOENT instead of NoSuchProcess.
- 1627_: [Linux] Process.memory_maps() can raise KeyError.
- 1642_: [SunOS] querying basic info for PID 0 results in FileNotFoundError.
- 1646_: [FreeBSD] many Process methods may cause a segfault on FreeBSD 12.0
due to a backward incompatible change in a C type introduced in 12.0.
- 1656_: [Windows] Process.memory_full_info() raises AccessDenied even for the
current user and os.getpid().
- 1660_: [Windows] Process.open_files() complete rewrite + check of errors.
- 1662_: [Windows] process exe() may raise WinError 0.
- 1665_: [Linux] disk_io_counters() does not take into account extra fields
added to recent kernels.  (patch by Mike Hommey)
- 1672_: use the right C type when dealing with PIDs (int or long). Thus far
(long) was almost always assumed, which is wrong on most platforms.
- 1673_: [OpenBSD] Process connections(), num_fds() and threads() returned
improper exception if process is gone.
- 1674_: [SunOS] disk_partitions() may raise OSError.
- 1684_: [Linux] disk_io_counters() may raise ValueError on systems not
having /proc/diskstats.
- 1695_: [Linux] could not compile on kernels <= 2.6.13 due to
PSUTIL_HAVE_IOPRIO not being defined.  (patch by Anselm Kruis)

5.6.7

=====

2019-11-26

**Bug fixes**

- 1630_: [Windows] can't compile source distribution due to C syntax error.

5.6.6

=====

2019-11-25

**Bug fixes**

- 1179_: [Linux] Process cmdline() now takes into account misbehaving processes
renaming the command line and using inappropriate chars to separate args.
- 1616_: use of Py_DECREF instead of Py_CLEAR will result in double free and
segfault
(`CVE-2019-18874 <https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-18874>`__).
(patch by Riccardo Schirone)
- 1619_: [OpenBSD] compilation fails due to C syntax error.  (patch by Nathan
Houghton)

5.6.5

=====

2019-11-06

**Bug fixes**

- 1615_: remove pyproject.toml as it was causing installation issues.

5.6.4

=====

2019-11-04

**Enhancements**

- 1527_: [Linux] added Process.cpu_times().iowait counter, which is the time
spent waiting for blocking I/O to complete.
- 1565_: add PEP 517/8 build backend and requirements specification for better
pip integration.  (patch by Bernát Gábor)

**Bug fixes**

- 875_: [Windows] Process' cmdline(), environ() or cwd() may occasionally fail
with ERROR_PARTIAL_COPY which now gets translated to AccessDenied.
- 1126_: [Linux] cpu_affinity() segfaults on CentOS 5 / manylinux.
cpu_affinity() support for CentOS 5 was removed.
- 1528_: [AIX] compilation error on AIX 7.2 due to 32 vs 64 bit differences.
(patch by Arnon Yaari)
- 1535_: 'type' and 'family' fields returned by net_connections() are not
always turned into enums.
- 1536_: [NetBSD] process cmdline() erroneously raise ZombieProcess error if
cmdline has non encodable chars.
- 1546_: usage percent may be rounded to 0 on Python 2.
- 1552_: [Windows] getloadavg() math for calculating 5 and 15 mins values is
incorrect.
- 1568_: [Linux] use CC compiler env var if defined.
- 1570_: [Windows] `NtWow64*` syscalls fail to raise the proper error code
- 1585_: [OSX] calling close() (in C) on possible negative integers.  (patch
by Athos Ribeiro)
- 1606_: [SunOS] compilation fails on SunOS 5.10.  (patch by vser1)

5.6.3

=====

2019-06-11

**Enhancements**

- 1494_: [AIX] added support for Process.environ().  (patch by Arnon Yaari)

**Bug fixes**

- 1276_: [AIX] can't get whole cmdline().  (patch by Arnon Yaari)
- 1501_: [Windows] Process cmdline() and exe() raise unhandled "WinError 1168
element not found" exceptions for "Registry" and "Memory Compression" psuedo
processes on Windows 10.
- 1526_: [NetBSD] process cmdline() could raise MemoryError.  (patch by
Kamil Rytarowski)

5.6.2

=====

2019-04-26

**Enhancements**

- 604_: [Windows, Windows] add new psutil.getloadavg(), returning system load
average calculation, including on Windows (emulated).  (patch by Ammar Askar)
- 1404_: [Linux] cpu_count(logical=False) uses a second method (read from
`/sys/devices/system/cpu/cpu[0-9]/topology/core_id`) in order to determine
the number of physical CPUs in case /proc/cpuinfo does not provide this info.
- 1458_: provide coloured test output. Also show failures on KeyboardInterrupt.
- 1464_: various docfixes (always point to python3 doc, fix links, etc.).
- 1476_: [Windows] it is now possible to set process high I/O priority
(ionice()).Also, I/O priority values are now exposed as 4 new constants:
IOPRIO_VERYLOW, IOPRIO_LOW, IOPRIO_NORMAL, IOPRIO_HIGH.
- 1478_: add make command to re-run tests failed on last run.

**Bug fixes**

- 1223_: [Windows] boot_time() may return value on Windows XP.
- 1456_: [Linux] cpu_freq() returns None instead of 0.0 when min/max not
available (patch by Alex Manuskin)
- 1462_: [Linux] (tests) make tests invariant to LANG setting (patch by
Benjamin Drung)
- 1463_: cpu_distribution.py script was broken.
- 1470_: [Linux] disk_partitions(): fix corner case when /etc/mtab doesn't
exist.  (patch by Cedric Lamoriniere)
- 1471_: [SunOS] Process name() and cmdline() can return SystemError.  (patch
by Daniel Beer)
- 1472_: [Linux] cpu_freq() does not return all CPUs on Rasbperry-pi 3.
- 1474_: fix formatting of psutil.tests() which mimicks 'ps aux' output.
- 1475_: [Windows] OSError.winerror attribute wasn't properly checked resuling
in WindowsError being raised instead of AccessDenied.
- 1477_: [Windows] wrong or absent error handling for private NTSTATUS Windows
APIs. Different process methods were affected by this.
- 1480_: [Windows] psutil.cpu_count(logical=False) could cause a crash due to
fixed read violation.  (patch by Samer Masterson)
- 1486_: [AIX, SunOS] AttributeError when interacting with Process methods
involved into oneshot() context.
- 1491_: [SunOS] net_if_addrs(): free() ifap struct on error.  (patch by
Agnewee)
- 1493_: [Linux] cpu_freq(): handle the case where
/sys/devices/system/cpu/cpufreq/ exists but is empty.

5.6.1

=====

2019-03-11

**Bug fixes**

- 1329_: [AIX] psutil doesn't compile on AIX 6.1.  (patch by Arnon Yaari)
- 1448_: [Windows] crash on import due to rtlIpv6AddressToStringA not available
on Wine.
- 1451_: [Windows] Process.memory_full_info() segfaults. NtQueryVirtualMemory
is now used instead of QueryWorkingSet to calculate USS memory.

5.6.0

=====

2019-03-05

**Enhancements**

- 1379_: [Windows] Process suspend() and resume() now use NtSuspendProcess
and NtResumeProcess instead of stopping/resuming all threads of a process.
This is faster and more reliable (aka this is what ProcessHacker does).
- 1420_: [Windows] in case of exception disk_usage() now also shows the path
name.
- 1422_: [Windows] Windows APIs requiring to be dynamically loaded from DLL
libraries are now loaded only once on startup (instead of on per function
call) significantly speeding up different functions and methods.
- 1426_: [Windows] PAGESIZE and number of processors is now calculated on
startup.
- 1428_: in case of error, the traceback message now shows the underlying C
function called which failed.
- 1433_: new Process.parents() method.  (idea by Ghislain Le Meur)
- 1437_: pids() are returned in sorted order.
- 1442_: python3 is now the default interpreter used by Makefile.

**Bug fixes**

- 1353_: process_iter() is now thread safe (it rarely raised TypeError).
- 1394_: [Windows] Process name() and exe() may erroneously return "Registry".
QueryFullProcessImageNameW is now used instead of GetProcessImageFileNameW
in order to prevent that.
- 1411_: [BSD] lack of Py_DECREF could cause segmentation fault on process
instantiation.
- 1419_: [Windows] Process.environ() raises NotImplementedError when querying
a 64-bit process in 32-bit-WoW mode. Now it raises AccessDenied.
- 1427_: [OSX] Process cmdline() and environ() may erroneously raise OSError
on failed malloc().
- 1429_: [Windows] SE DEBUG was not properly set for current process. It is
now, and it should result in less AccessDenied exceptions for low-pid
processes.
- 1432_: [Windows] Process.memory_info_ex()'s USS memory is miscalculated
because we're not using the actual system PAGESIZE.
- 1439_: [NetBSD] Process.connections() may return incomplete results if using
oneshot().
- 1447_: original exception wasn't turned into NSP/AD exceptions when using
Process.oneshot() ctx manager.

**Incompatible API changes**

- 1291_: [OSX] Process.memory_maps() was removed because inherently broken
(segfault) for years.

5.5.1

=====

2019-02-15

**Enhancements**

- 1348_: [Windows] on Windows >= 8.1 if Process.cmdline() fails due to
ERROR_ACCESS_DENIED attempt using NtQueryInformationProcess +
ProcessCommandLineInformation. (patch by EccoTheFlintstone)

**Bug fixes**

- 1394_: [Windows] Process.exe() returns "[Error 0] The operation completed
successfully" when Python process runs in "Virtual Secure Mode".
- 1402_: psutil exceptions' repr() show the internal private module path.
- 1408_: [AIX] psutil won't compile on AIX 7.1 due to missing header.  (patch
by Arnon Yaari)

5.5.0

=====

2019-01-23

**Enhancements**

- 1350_: [FreeBSD] added support for sensors_temperatures().  (patch by Alex
Manuskin)
- 1352_: [FreeBSD] added support for CPU frequency.  (patch by Alex Manuskin)

**Bug fixes**

- 1111_: Process.oneshot() is now thread safe.
- 1354_: [Linux] disk_io_counters() fails on Linux kernel 4.18+.
- 1357_: [Linux] Process' memory_maps() and io_counters() method are no longer
exposed if not supported by the kernel.
- 1368_: [Windows] fix psutil.Process().ionice(...) mismatch.  (patch by
EccoTheFlintstone)
- 1370_: [Windows] improper usage of CloseHandle() may lead to override the
original error code when raising an exception.
- 1373_: incorrect handling of cache in Process.oneshot() context causes
Process instances to return incorrect results.
- 1376_: [Windows] OpenProcess() now uses PROCESS_QUERY_LIMITED_INFORMATION
access rights wherever possible, resulting in less AccessDenied exceptions
being thrown for system processes.
- 1376_: [Windows] check if variable is NULL before free()ing it.  (patch by
EccoTheFlintstone)

5.4.8

=====

2018-10-30

**Enhancements**

- 1197_: [Linux] cpu_freq() is now implemented by parsing /proc/cpuinfo in case
/sys/devices/system/cpu/* filesystem is not available.
- 1310_: [Linux] psutil.sensors_temperatures() now parses /sys/class/thermal
in case /sys/class/hwmon fs is not available (e.g. Raspberry Pi).  (patch
by Alex Manuskin)
- 1320_: [Posix] better compilation support when using g++ instead of gcc.
(patch by Jaime Fullaondo)

**Bug fixes**

- 715_: do not print exception on import time in case cpu_times() fails.
- 1004_: [Linux] Process.io_counters() may raise ValueError.
- 1277_: [OSX] available and used memory (psutil.virtual_memory()) metrics are
not accurate.
- 1294_: [Windows] psutil.Process().connections() may sometimes fail with
intermittent 0xC0000001.  (patch by Sylvain Duchesne)
- 1307_: [Linux] disk_partitions() does not honour PROCFS_PATH.
- 1320_: [AIX] system CPU times (psutil.cpu_times()) were being reported with
ticks unit as opposed to seconds.  (patch by Jaime Fullaondo)
- 1332_: [OSX] psutil debug messages are erroneously printed all the time.
(patch by Ilya Yanok)
- 1346_: [SunOS] net_connections() returns an empty list.  (patch by Oleksii
Shevchuk)

5.4.7

=====

2018-08-14

**Enhancements**

- 1286_: [macOS] psutil.OSX constant is now deprecated in favor of new
psutil.MACOS.
- 1309_: [Linux] added psutil.STATUS_PARKED constant for Process.status().
- 1321_: [Linux] add disk_io_counters() dual implementation relying on
/sys/block filesystem in case /proc/diskstats is not available. (patch by
Lawrence Ye)

**Bug fixes**

- 1209_: [macOS] Process.memory_maps() may fail with EINVAL due to poor
task_for_pid() syscall. AccessDenied is now raised instead.
- 1278_: [macOS] Process.threads() incorrectly return microseconds instead of
seconds. (patch by Nikhil Marathe)
- 1279_: [Linux, macOS, BSD] net_if_stats() may return ENODEV.
- 1294_: [Windows] psutil.Process().connections() may sometime fail with
MemoryError.  (patch by sylvainduchesne)
- 1305_: [Linux] disk_io_stats() may report inflated r/w bytes values.
- 1309_: [Linux] Process.status() is unable to recognize "idle" and "parked"
statuses (returns '?').
- 1313_: [Linux] disk_io_counters() can report inflated IO counters due to
erroneously counting base disk device and its partition(s) twice.
- 1323_: [Linux] sensors_temperatures() may fail with ValueError.

5.4.6

=====

2018-06-07

**Bug fixes**

- 1258_: [Windows] Process.username() may cause a segfault (Python interpreter
crash).  (patch by Jean-Luc Migot)
- 1273_: net_if_addr() namedtuple's name has been renamed from "snic" to
"snicaddr".
- 1274_: [Linux] there was a small chance Process.children() may swallow
AccessDenied exceptions.

5.4.5

=====

2018-04-14

**Bug fixes**

- 1268_: setup.py's extra_require parameter requires latest setuptools version,
breaking quite a lot of installations.

5.4.4

=====

2018-04-13

**Enhancements**

- 1239_: [Linux] expose kernel "slab" memory for psutil.virtual_memory().
(patch by Maxime Mouial)

**Bug fixes**

- 694_: [SunOS] cmdline() could be truncated at the 15th character when
reading it from /proc. An extra effort is made by reading it from process
address space first.  (patch by Georg Sauthoff)
- 771_: [Windows] cpu_count() (both logical and physical) return a wrong
(smaller) number on systems using process groups (> 64 cores).
- 771_: [Windows] cpu_times(percpu=True) return fewer CPUs on systems using
process groups (> 64 cores).
- 771_: [Windows] cpu_stats() and cpu_freq() may return incorrect results on
systems using process groups (> 64 cores).
- 1193_: [SunOS] Return uid/gid from /proc/pid/psinfo if there aren't
enough permissions for /proc/pid/cred.  (patch by Georg Sauthoff)
- 1194_: [SunOS] Return nice value from psinfo as getpriority() doesn't
support real-time processes.  (patch by Georg Sauthoff)
- 1194_: [SunOS] Fix double free in psutil_proc_cpu_num().  (patch by Georg
Sauthoff)
- 1194_: [SunOS] Fix undefined behavior related to strict-aliasing rules
and warnings.  (patch by Georg Sauthoff)
- 1210_: [Linux] cpu_percent() steal time may remain stuck at 100% due to Linux
erroneously reporting a decreased steal time between calls. (patch by Arnon
Yaari)
- 1216_: fix compatibility with python 2.6 on Windows (patch by Dan Vinakovsky)
- 1222_: [Linux] Process.memory_full_info() was erroneously summing "Swap:" and
"SwapPss:". Same for "Pss:" and "SwapPss". Not anymore.
- 1224_: [Windows] Process.wait() may erroneously raise TimeoutExpired.
- 1238_: [Linux] sensors_battery() may return None in case battery is not
listed as "BAT0" under /sys/class/power_supply.
- 1240_: [Windows] cpu_times() float loses accuracy in a long running system.
(patch by stswandering)
- 1245_: [Linux] sensors_temperatures() may fail with IOError "no such file".
- 1255_: [FreeBSD] swap_memory() stats were erroneously represented in KB.
(patch by Denis Krienbühl)

**Backward compatibility**

- 771_: [Windows] cpu_count(logical=False) on Windows XP and Vista is no
longer supported and returns None.

5.4.3

=====

*2018-01-01*

**Enhancements**

- 775_: disk_partitions() on Windows return mount points.

**Bug fixes**

- 1193_: pids() may return False on macOS.

5.4.2

=====

*2017-12-07*

**Enhancements**

- 1173_: introduced PSUTIL_DEBUG environment variable which can be set in order
to print useful debug messages on stderr (useful in case of nasty errors).
- 1177_: added support for sensors_battery() on macOS.  (patch by Arnon Yaari)
- 1183_: Process.children() is 2x faster on UNIX and 2.4x faster on Linux.
- 1188_: deprecated method Process.memory_info_ex() now warns by using
FutureWarning instead of DeprecationWarning.

**Bug fixes**

- 1152_: [Windows] disk_io_counters() may return an empty dict.
- 1169_: [Linux] users() "hostname" returns username instead.  (patch by
janderbrain)
- 1172_: [Windows] `make test` does not work.
- 1179_: [Linux] Process.cmdline() is now able to splits cmdline args for
misbehaving processes which overwrite /proc/pid/cmdline and use spaces
instead of null bytes as args separator.
- 1181_: [macOS] Process.memory_maps() may raise ENOENT.
- 1187_: [macOS] pids() does not return PID 0 on recent macOS versions.

5.4.1

=====

*2017-11-08*

**Enhancements**

- 1164_: [AIX] add support for Process.num_ctx_switches().  (patch by Arnon
Yaari)
- 1053_: abandon Python 3.3 support (psutil still works but it's no longer
tested).

**Bug fixes**

- 1150_: [Windows] when a process is terminate()d now the exit code is set to
SIGTERM instead of 0.  (patch by Akos Kiss)
- 1151_: python -m psutil.tests fail
- 1154_: [AIX] psutil won't compile on AIX 6.1.0.  (patch by Arnon Yaari)
- 1167_: [Windows] net_io_counter() packets count now include also non-unicast
packets.  (patch by Matthew Long)

5.4.0

=====

*2017-10-12*

**Enhancements**

- 1123_: [AIX] added support for AIX platform.  (patch by Arnon Yaari)

**Bug fixes**

- 1009_: [Linux] sensors_temperatures() may crash with IOError.
- 1012_: [Windows] disk_io_counters()'s read_time and write_time were expressed
in tens of micro seconds instead of milliseconds.
- 1127_: [macOS] invalid reference counting in Process.open_files() may lead to
segfault.  (patch by Jakub Bacic)
- 1129_: [Linux] sensors_fans() may crash with IOError.  (patch by Sebastian
Saip)
- 1131_: [SunOS] fix compilation warnings.  (patch by Arnon Yaari)
- 1133_: [Windows] can't compile on newer versions of Visual Studio 2017 15.4.
(patch by Max Bélanger)
- 1138_: [Linux] can't compile on CentOS 5.0 and RedHat 5.0.
(patch by Prodesire)

5.3.1

=====

*2017-09-10*

**Enhancements**

- 1124_: documentation moved to http://psutil.readthedocs.io

**Bug fixes**

- 1105_: [FreeBSD] psutil does not compile on FreeBSD 12.
- 1125_: [BSD] net_connections() raises TypeError.

**Compatibility notes**

- 1120_: .exe files for Windows are no longer uploaded on PyPI as per PEP-527;
only wheels are provided.

5.3.0

=====

*2017-09-01*

**Enhancements**

- 802_: disk_io_counters() and net_io_counters() numbers no longer wrap
(restart from 0). Introduced a new "nowrap" argument.
- 928_: psutil.net_connections() and psutil.Process.connections() "laddr" and
"raddr" are now named tuples.
- 1015_: swap_memory() now relies on /proc/meminfo instead of sysinfo() syscall
so that it can be used in conjunction with PROCFS_PATH in order to retrieve
memory info about Linux containers such as Docker and Heroku.
- 1022_: psutil.users() provides a new "pid" field.
- 1025_: process_iter() accepts two new parameters in order to invoke
Process.as_dict(): "attrs" and "ad_value". With this you can iterate over all
processes in one shot without needing to catch NoSuchProcess and do list/dict
comprehensions.
- 1040_: implemented full unicode support.
- 1051_: disk_usage() on Python 3 is now able to accept bytes.
- 1058_: test suite now enables all warnings by default.
- 1060_: source distribution is dynamically generated so that it only includes
relevant files.
- 1079_: [FreeBSD] net_connections()'s fd number is now being set for real
(instead of -1).  (patch by Gleb Smirnoff)
- 1091_: [SunOS] implemented Process.environ().  (patch by Oleksii Shevchuk)

**Bug fixes**

- 989_: [Windows] boot_time() may return a negative value.
- 1007_: [Windows] boot_time() can have a 1 sec fluctuation between calls; the
value of the first call is now cached so that boot_time() always returns the
same value if fluctuation is <= 1 second.
- 1013_: [FreeBSD] psutil.net_connections() may return incorrect PID.  (patch
by Gleb Smirnoff)
- 1014_: [Linux] Process class can mask legitimate ENOENT exceptions as
NoSuchProcess.
- 1016_: disk_io_counters() raises RuntimeError on a system with no disks.
- 1017_: net_io_counters() raises RuntimeError on a system with no network
cards installed.
- 1021_: [Linux] open_files() may erroneously raise NoSuchProcess instead of
skipping a file which gets deleted while open files are retrieved.
- 1029_: [macOS, FreeBSD] Process.connections('unix') on Python 3 doesn't
properly handle unicode paths and may raise UnicodeDecodeError.
- 1033_: [macOS, FreeBSD] memory leak for net_connections() and
Process.connections() when retrieving UNIX sockets (kind='unix').
- 1040_: fixed many unicode related issues such as UnicodeDecodeError on
Python 3 + UNIX and invalid encoded data on Windows.
- 1042_: [FreeBSD] psutil won't compile on FreeBSD 12.
- 1044_: [macOS] different Process methods incorrectly raise AccessDenied for
zombie processes.
- 1046_: [Windows] disk_partitions() on Windows overrides user's SetErrorMode.
- 1047_: [Windows] Process username(): memory leak in case exception is thrown.
- 1048_: [Windows] users()'s host field report an invalid IP address.
- 1050_: [Windows] Process.memory_maps memory() leaks memory.
- 1055_: cpu_count() is no longer cached; this is useful on systems such as
Linux where CPUs can be disabled at runtime. This also reflects on
Process.cpu_percent() which no longer uses the cache.
- 1058_: fixed Python warnings.
- 1062_: disk_io_counters() and net_io_counters() raise TypeError if no disks
or NICs are installed on the system.
- 1063_: [NetBSD] net_connections() may list incorrect sockets.
- 1064_: [NetBSD] swap_memory() may segfault in case of error.
- 1065_: [OpenBSD] Process.cmdline() may raise SystemError.
- 1067_: [NetBSD] Process.cmdline() leaks memory if process has terminated.
- 1069_: [FreeBSD] Process.cpu_num() may return 255 for certain kernel
processes.
- 1071_: [Linux] cpu_freq() may raise IOError on old RedHat distros.
- 1074_: [FreeBSD] sensors_battery() raises OSError in case of no battery.
- 1075_: [Windows] net_if_addrs(): inet_ntop() return value is not checked.
- 1077_: [SunOS] net_if_addrs() shows garbage addresses on SunOS 5.10.
(patch by Oleksii Shevchuk)
- 1077_: [SunOS] net_connections() does not work on SunOS 5.10. (patch by
Oleksii Shevchuk)
- 1079_: [FreeBSD] net_connections() didn't list locally connected sockets.
(patch by Gleb Smirnoff)
- 1085_: cpu_count() return value is now checked and forced to None if <= 1.
- 1087_: Process.cpu_percent() guard against cpu_count() returning None and
assumes 1 instead.
- 1093_: [SunOS] memory_maps() shows wrong 64 bit addresses.
- 1094_: [Windows] psutil.pid_exists() may lie. Also, all process APIs relying
on OpenProcess Windows API now check whether the PID is actually running.
- 1098_: [Windows] Process.wait() may erroneously return sooner, when the PID
is still alive.
- 1099_: [Windows] Process.terminate() may raise AccessDenied even if the
process already died.
- 1101_: [Linux] sensors_temperatures() may raise ENODEV.

**Porting notes**

- 1039_: returned types consolidation:
- Windows / Process.cpu_times(): fields 3 and 4 were int instead of float
- Linux / FreeBSD: connections('unix'): raddr is now set to "" instead of
 None
- OpenBSD: connections('unix'): laddr and raddr are now set to "" instead of
 None
- 1040_: all strings are encoded by using OS fs encoding.
- 1040_: the following Windows APIs on Python 2 now return a string instead of
unicode:
- Process.memory_maps().path
- WindowsService.bin_path()
- WindowsService.description()
- WindowsService.display_name()
- WindowsService.username()

5.2.2

=====

*2017-04-10*

**Bug fixes**

- 1000_: fixed some setup.py warnings.
- 1002_: [SunOS] remove C macro which will not be available on new Solaris
versions. (patch by Danek Duvall)
- 1004_: [Linux] Process.io_counters() may raise ValueError.
- 1006_: [Linux] cpu_freq() may return None on some Linux versions does not
support the function; now the function is not declared instead.
- 1009_: [Linux] sensors_temperatures() may raise OSError.
- 1010_: [Linux] virtual_memory() may raise ValueError on Ubuntu 14.04.

5.2.1

=====

*2017-03-24*

**Bug fixes**

- 981_: [Linux] cpu_freq() may return an empty list.
- 993_: [Windows] Process.memory_maps() on Python 3 may raise
UnicodeDecodeError.
- 996_: [Linux] sensors_temperatures() may not show all temperatures.
- 997_: [FreeBSD] virtual_memory() may fail due to missing sysctl parameter on
FreeBSD 12.

5.2.0

=====

*2017-03-05*

**Enhancements**

- 971_: [Linux] Add psutil.sensors_fans() function.  (patch by Nicolas Hennion)
- 976_: [Windows] Process.io_counters() has 2 new fields: *other_count* and
*other_bytes*.
- 976_: [Linux] Process.io_counters() has 2 new fields: *read_chars* and
*write_chars*.

**Bug fixes**

- 872_: [Linux] can now compile on Linux by using MUSL C library.
- 985_: [Windows] Fix a crash in `Process.open_files` when the worker thread
for `NtQueryObject` times out.
- 986_: [Linux] Process.cwd() may raise NoSuchProcess instead of ZombieProcess.

5.1.3

=====

**Bug fixes**

- 971_: [Linux] sensors_temperatures() didn't work on CentOS 7.
- 973_: cpu_percent() may raise ZeroDivisionError.

5.1.2

=====

*2017-02-03*

**Bug fixes**

- 966_: [Linux] sensors_battery().power_plugged may erroneously return None on
Python 3.
- 968_: [Linux] disk_io_counters() raises TypeError on python 3.
- 970_: [Linux] sensors_battery()'s name and label fields on Python 3 are bytes
instead of str.

5.1.1

=====

*2017-02-03*

**Enhancements**

- 966_: [Linux] sensors_battery().percent is a float and is more precise.

**Bug fixes**

- 964_: [Windows] Process.username() and psutil.users() may return badly
decoding character on Python 3.
- 965_: [Linux] disk_io_counters() may miscalculate sector size and report the
wrong number of bytes read and written.
- 966_: [Linux] sensors_battery() may fail with "no such file error".
- 966_: [Linux] sensors_battery().power_plugged may lie.

5.1.0

=====

*2017-02-01*

**Enhancements**

- 357_: added psutil.Process.cpu_num() (what CPU a process is on).
- 371_: added psutil.sensors_temperatures() (Linux only).
- 941_: added psutil.cpu_freq() (CPU frequency).
- 955_: added psutil.sensors_battery() (Linux, Windows, only).
- 956_: cpu_affinity([]) can now be used as an alias to set affinity against
all eligible CPUs.

**Bug fixes**

- 687_: [Linux] pid_exists() no longer returns True if passed a process thread
ID.
- 948_: cannot install psutil with PYTHONOPTIMIZE=2.
- 950_: [Windows] Process.cpu_percent() was calculated incorrectly and showed
higher number than real usage.
- 951_: [Windows] the uploaded wheels for Python 3.6 64 bit didn't work.
- 959_: psutil exception objects could not be pickled.
- 960_: Popen.wait() did not return the correct negative exit status if process
is ``kill()``ed by a signal.
- 961_: [Windows] WindowsService.description() may fail with
ERROR_MUI_FILE_NOT_FOUND.

5.0.1

=====

*2016-12-21*

**Enhancements**

- 939_: tar.gz distribution went from 1.8M to 258K.
- 811_: [Windows] provide a more meaningful error message if trying to use
psutil on unsupported Windows XP.

**Bug fixes**

- 609_: [SunOS] psutil does not compile on Solaris 10.
- 936_: [Windows] fix compilation error on VS 2013 (patch by Max Bélanger).
- 940_: [Linux] cpu_percent() and cpu_times_percent() was calculated
incorrectly as "iowait", "guest" and "guest_nice" times were not properly
taken into account.
- 944_: [OpenBSD] psutil.pids() was omitting PID 0.

5.0.0

=====

*2016-11-06*

**Enhncements**

- 799_: new Process.oneshot() context manager making Process methods around
+2x faster in general and from +2x to +6x faster on Windows.
- 943_: better error message in case of version conflict on import.

**Bug fixes**

- 932_: [NetBSD] net_connections() and Process.connections() may fail without
raising an exception.
- 933_: [Windows] memory leak in cpu_stats() and WindowsService.description().

4.4.2

=====

*2016-10-26*

**Bug fixes**

- 931_: psutil no longer compiles on Solaris.

4.4.1

=====

*2016-10-25*

**Bug fixes**

- 927_: ``Popen.__del__`` may cause maximum recursion depth error.

4.4.0

=====

*2016-10-23*

**Enhancements**

- 874_: [Windows] net_if_addrs() returns also the netmask.
- 887_: [Linux] virtual_memory()'s 'available' and 'used' values are more
precise and match "free" cmdline utility.  "available" also takes into
account LCX containers preventing "available" to overflow "total".
- 891_: procinfo.py script has been updated and provides a lot more info.

**Bug fixes**

- 514_: [macOS] possibly fix Process.memory_maps() segfault (critical!).
- 783_: [macOS] Process.status() may erroneously return "running" for zombie
processes.
- 798_: [Windows] Process.open_files() returns and empty list on Windows 10.
- 825_: [Linux] cpu_affinity; fix possible double close and use of unopened
socket.
- 880_: [Windows] Handle race condition inside psutil_net_connections.
- 885_: ValueError is raised if a negative integer is passed to cpu_percent()
functions.
- 892_: [Linux] Process.cpu_affinity([-1]) raise SystemError with no error
set; now ValueError is raised.
- 906_: [BSD] disk_partitions(all=False) returned an empty list. Now the
argument is ignored and all partitions are always returned.
- 907_: [FreeBSD] Process.exe() may fail with OSError(ENOENT).
- 908_: [macOS, BSD] different process methods could errounesuly mask the real
error for high-privileged PIDs and raise NoSuchProcess and AccessDenied
instead of OSError and RuntimeError.
- 909_: [macOS] Process open_files() and connections() methods may raise
OSError with no exception set if process is gone.
- 916_: [macOS] fix many compilation warnings.

4.3.1

=====

*2016-09-01*

**Enhancements**

- 881_: "make install" now works also when using a virtual env.

**Bug fixes**

- 854_: Process.as_dict() raises ValueError if passed an erroneous attrs name.
- 857_: [SunOS] Process cpu_times(), cpu_percent(), threads() amd memory_maps()
may raise RuntimeError if attempting to query a 64bit process with a 32bit
python. "Null" values are returned as a fallback.
- 858_: Process.as_dict() should not return memory_info_ex() because it's
deprecated.
- 863_: [Windows] memory_map truncates addresses above 32 bits
- 866_: [Windows] win_service_iter() and services in general are not able to
handle unicode service names / descriptions.
- 869_: [Windows] Process.wait() may raise TimeoutExpired with wrong timeout
unit (ms instead of sec).
- 870_: [Windows] Handle leak inside psutil_get_process_data.

4.3.0

=====

*2016-06-18*

**Enhancements**

- 819_: [Linux] different speedup improvements:
Process.ppid() is 20% faster
Process.status() is 28% faster
Process.name() is 25% faster
Process.num_threads is 20% faster on Python 3

**Bug fixes**

- 810_: [Windows] Windows wheels are incompatible with pip 7.1.2.
- 812_: [NetBSD] fix compilation on NetBSD-5.x.
- 823_: [NetBSD] virtual_memory() raises TypeError on Python 3.
- 829_: [UNIX] psutil.disk_usage() percent field takes root reserved space
into account.
- 816_: [Windows] fixed net_io_counter() values wrapping after 4.3GB in
Windows Vista (NT 6.0) and above using 64bit values from newer win APIs.

4.2.0

=====

*2016-05-14*

**Enhancements**

- 795_: [Windows] new APIs to deal with Windows services: win_service_iter()
and win_service_get().
- 800_: [Linux] psutil.virtual_memory() returns a new "shared" memory field.
- 819_: [Linux] speedup /proc parsing:
- Process.ppid() is 20% faster
- Process.status() is 28% faster
- Process.name() is 25% faster
- Process.num_threads is 20% faster on Python 3

**Bug fixes**

- 797_: [Linux] net_if_stats() may raise OSError for certain NIC cards.
- 813_: Process.as_dict() should ignore extraneous attribute names which gets
attached to the Process instance.

4.1.0

=====

*2016-03-12*

**Enhancements**

- 777_: [Linux] Process.open_files() on Linux return 3 new fields: position,
mode and flags.
- 779_: Process.cpu_times() returns two new fields, 'children_user' and
'children_system' (always set to 0 on macOS and Windows).
- 789_: [Windows] psutil.cpu_times() return two new fields: "interrupt" and
"dpc". Same for psutil.cpu_times_percent().
- 792_: new psutil.cpu_stats() function returning number of CPU ctx switches
interrupts, soft interrupts and syscalls.

**Bug fixes**

- 774_: [FreeBSD] net_io_counters() dropout is no longer set to 0 if the kernel
provides it.
- 776_: [Linux] Process.cpu_affinity() may erroneously raise NoSuchProcess.
(patch by wxwright)
- 780_: [macOS] psutil does not compile with some gcc versions.
- 786_: net_if_addrs() may report incomplete MAC addresses.
- 788_: [NetBSD] virtual_memory()'s buffers and shared values were set to 0.
- 790_: [macOS] psutil won't compile on macOS 10.4.

4.0.0

=====

*2016-02-17*

**Enhancements**

- 523_: [Linux, FreeBSD] disk_io_counters() return a new "busy_time" field.
- 660_: [Windows] make.bat is smarter in finding alternative VS install
locations.  (patch by mpderbec)
- 732_: Process.environ().  (patch by Frank Benkstein)
- 753_: [Linux, macOS, Windows] Process USS and PSS (Linux) "real" memory stats.
(patch by Eric Rahm)
- 755_: Process.memory_percent() "memtype" parameter.
- 758_: tests now live in psutil namespace.
- 760_: expose OS constants (psutil.LINUX, psutil.macOS, etc.)
- 756_: [Linux] disk_io_counters() return 2 new fields: read_merged_count and
write_merged_count.
- 762_: new scripts/procsmem.py script.

**Bug fixes**

- 685_: [Linux] virtual_memory() provides wrong results on systems with a lot
of physical memory.
- 704_: [Solaris] psutil does not compile on Solaris sparc.
- 734_: on Python 3 invalid UTF-8 data is not correctly handled for process
name(), cwd(), exe(), cmdline() and open_files() methods resulting in
UnicodeDecodeError exceptions. 'surrogateescape' error handler is now
used as a workaround for replacing the corrupted data.
- 737_: [Windows] when the bitness of psutil and the target process was
different cmdline() and cwd() could return a wrong result or incorrectly
report an AccessDenied error.
- 741_: [OpenBSD] psutil does not compile on mips64.
- 751_: [Linux] fixed call to Py_DECREF on possible Null object.
- 754_: [Linux] cmdline() can be wrong in case of zombie process.
- 759_: [Linux] Process.memory_maps() may return paths ending with " (deleted)"
- 761_: [Windows] psutil.boot_time() wraps to 0 after 49 days.
- 764_: [NetBSD] fix compilation on NetBSD-6.x.
- 766_: [Linux] net_connections() can't handle malformed /proc/net/unix file.
- 767_: [Linux] disk_io_counters() may raise ValueError on 2.6 kernels and it's
broken on 2.4 kernels.
- 770_: [NetBSD] disk_io_counters() metrics didn't update.

3.4.2

=====

*2016-01-20*

**Enhancements**

- 728_: [Solaris] exposed psutil.PROCFS_PATH constant to change the default
location of /proc filesystem.

**Bug fixes**

- 724_: [FreeBSD] psutil.virtual_memory().total is incorrect.
- 730_: [FreeBSD] psutil.virtual_memory() crashes.

3.4.1

=====

*2016-01-15*

**Enhancements**

- 557_: [NetBSD] added NetBSD support.  (contributed by Ryo Onodera and
Thomas Klausner)
- 708_: [Linux] psutil.net_connections() and Process.connections() on Python 2
can be up to 3x faster in case of many connections.
Also psutil.Process.memory_maps() is slightly faster.
- 718_: process_iter() is now thread safe.

**Bug fixes**

- 714_: [OpenBSD] virtual_memory().cached value was always set to 0.
- 715_: don't crash at import time if cpu_times() fail for some reason.
- 717_: [Linux] Process.open_files fails if deleted files still visible.
- 722_: [Linux] swap_memory() no longer crashes if sin/sout can't be determined
due to missing /proc/vmstat.
- 724_: [FreeBSD] virtual_memory().total is slightly incorrect.

3.3.0

=====

*2015-11-25*

**Enhancements**

- 558_: [Linux] exposed psutil.PROCFS_PATH constant to change the default
location of /proc filesystem.
- 615_: [OpenBSD] added OpenBSD support.  (contributed by Landry Breuil)

**Bug fixes**

- 692_: [UNIX] Process.name() is no longer cached as it may change.

3.2.2

=====

*2015-10-04*

**Bug fixes**

- 517_: [SunOS] net_io_counters failed to detect network interfaces
correctly on Solaris 10
- 541_: [FreeBSD] disk_io_counters r/w times were expressed in seconds instead
of milliseconds.  (patch by dasumin)
- 610_: [SunOS] fix build and tests on Solaris 10
- 623_: [Linux] process or system connections raises ValueError if IPv6 is not
supported by the system.
- 678_: [Linux] can't install psutil due to bug in setup.py.
- 688_: [Windows] compilation fails with MSVC 2015, Python 3.5. (patch by
Mike Sarahan)

3.2.1

=====

*2015-09-03*

**Bug fixes**

- 677_: [Linux] can't install psutil due to bug in setup.py.

3.2.0

=====

*2015-09-02*

**Enhancements**

- 644_: [Windows] added support for CTRL_C_EVENT and CTRL_BREAK_EVENT signals
to use with Process.send_signal().
- 648_: CI test integration for macOS. (patch by Jeff Tang)
- 663_: [UNIX] net_if_addrs() now returns point-to-point (VPNs) addresses.
- 655_: [Windows] different issues regarding unicode handling were fixed. On
Python 2 all APIs returning a string will now return an encoded version of it
by using sys.getfilesystemencoding() codec. The APIs involved are:
- psutil.net_if_addrs()
- psutil.net_if_stats()
- psutil.net_io_counters()
- psutil.Process.cmdline()
- psutil.Process.name()
- psutil.Process.username()
- psutil.users()

**Bug fixes**

- 513_: [Linux] fixed integer overflow for RLIM_INFINITY.
- 641_: [Windows] fixed many compilation warnings.  (patch by Jeff Tang)
- 652_: [Windows] net_if_addrs() UnicodeDecodeError in case of non-ASCII NIC
names.
- 655_: [Windows] net_if_stats() UnicodeDecodeError in case of non-ASCII NIC
names.
- 659_: [Linux] compilation error on Suse 10. (patch by maozguttman)
- 664_: [Linux] compilation error on Alpine Linux. (patch by Bart van Kleef)
- 670_: [Windows] segfgault of net_if_addrs() in case of non-ASCII NIC names.
(patch by sk6249)
- 672_: [Windows] compilation fails if using Windows SDK v8.0. (patch by
Steven Winfield)
- 675_: [Linux] net_connections(); UnicodeDecodeError may occur when listing
UNIX sockets.

3.1.1

=====

*2015-07-15*

**Bug fixes**

- 603_: [Linux] ionice_set value range is incorrect.  (patch by spacewander)
- 645_: [Linux] psutil.cpu_times_percent() may produce negative results.
- 656_: 'from psutil import *' does not work.

3.1.0

=====

*2015-07-15*

**Enhancements**

- 534_: [Linux] disk_partitions() added support for ZFS filesystems.
- 646_: continuous tests integration for Windows with
https://ci.appveyor.com/project/giampaolo/psutil.
- 647_: new dev guide:
https://github.com/giampaolo/psutil/blob/master/docs/DEVGUIDE.rst
- 651_: continuous code quality test integration with scrutinizer-ci.com

**Bug fixes**

- 340_: [Windows] Process.open_files() no longer hangs. Instead it uses a
thred which times out and skips the file handle in case it's taking too long
to be retrieved.  (patch by Jeff Tang, PR 597)
- 627_: [Windows] Process.name() no longer raises AccessDenied for pids owned
by another user.
- 636_: [Windows] Process.memory_info() raise AccessDenied.
- 637_: [UNIX] raise exception if trying to send signal to Process PID 0 as it
will affect os.getpid()'s process group instead of PID 0.
- 639_: [Linux] Process.cmdline() can be truncated.
- 640_: [Linux] *connections functions may swallow errors and return an
incomplete list of connnections.
- 642_: repr() of exceptions is incorrect.
- 653_: [Windows] Add inet_ntop function for Windows XP to support IPv6.
- 641_: [Windows] Replace deprecated string functions with safe equivalents.

3.0.1

=====

*2015-06-18*

**Bug fixes**

- 632_: [Linux] better error message if cannot parse process UNIX connections.
- 634_: [Linux] Proces.cmdline() does not include empty string arguments.
- 635_: [UNIX] crash on module import if 'enum' package is installed on python
< 3.4.

3.0.0

=====

*2015-06-13*

**Enhancements**

- 250_: new psutil.net_if_stats() returning NIC statistics (isup, duplex,
speed, MTU).
- 376_: new psutil.net_if_addrs() returning all NIC addresses a-la ifconfig.
- 469_: on Python >= 3.4 ``IOPRIO_CLASS_*`` and ``*_PRIORITY_CLASS`` constants
returned by psutil.Process' ionice() and nice() methods are enums instead of
plain integers.
- 581_: add .gitignore. (patch by Gabi Davar)
- 582_: connection constants returned by psutil.net_connections() and
psutil.Process.connections() were turned from int to enums on Python > 3.4.
- 587_: Move native extension into the package.
- 589_: Process.cpu_affinity() accepts any kind of iterable (set, tuple, ...),
not only lists.
- 594_: all deprecated APIs were removed.
- 599_: [Windows] process name() can now be determined for all processes even
when running as a limited user.
- 602_: pre-commit GIT hook.
- 629_: enhanced support for py.test and nose test discovery and tests run.
- 616_: [Windows] Add inet_ntop function for Windows XP.

**Bug fixes**

- 428_: [all UNIXes except Linux] correct handling of zombie processes;
introduced new ZombieProcess exception class.
- 512_: [BSD] fix segfault in net_connections().
- 555_: [Linux] psutil.users() correctly handles ":0" as an alias for
"localhost"
- 579_: [Windows] Fixed open_files() for PID>64K.
- 579_: [Windows] fixed many compiler warnings.
- 585_: [FreeBSD] net_connections() may raise KeyError.
- 586_: [FreeBSD] cpu_affinity() segfaults on set in case an invalid CPU
number is provided.
- 593_: [FreeBSD] Process().memory_maps() segfaults.
- 606_: Process.parent() may swallow NoSuchProcess exceptions.
- 611_: [SunOS] net_io_counters has send and received swapped
- 614_: [Linux]: cpu_count(logical=False) return the number of physical CPUs
instead of physical cores.
- 618_: [SunOS] swap tests fail on Solaris when run as normal user
- 628_: [Linux] Process.name() truncates process name in case it contains
spaces or parentheses.
Links

@pyup-bot pyup-bot mentioned this pull request Feb 18, 2020
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

Successfully merging this pull request may close these issues.

1 participant