mirror of
https://github.com/powerline/powerline.git
synced 2025-07-28 00:04:39 +02:00
Merge remote-tracking branch 'kovidgoyal/fix-latest-psutil-network' into develop
This commit is contained in:
commit
69db1a905f
@ -497,6 +497,9 @@ try:
|
||||
import psutil
|
||||
|
||||
def _get_bytes(interface):
|
||||
try:
|
||||
io_counters = psutil.net_io_counters(pernic=True)
|
||||
except AttributeError:
|
||||
io_counters = psutil.network_io_counters(pernic=True)
|
||||
if_io = io_counters.get(interface)
|
||||
if not if_io:
|
||||
|
Loading…
x
Reference in New Issue
Block a user