aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras/statistics.py
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2021-10-01 19:30:48 -0400
committerKevin O'Connor <kevin@koconnor.net>2021-10-04 14:36:08 -0400
commitf1747b51182cbe4d77c991492b55fd2df12b4c18 (patch)
tree3da8d0349dbc0af81b25ce9c713cb3508cf75aff /klippy/extras/statistics.py
parentb8c91914b75c23bae05b29c9c0ebf2bff35a9b4a (diff)
downloadkutter-f1747b51182cbe4d77c991492b55fd2df12b4c18.tar.gz
kutter-f1747b51182cbe4d77c991492b55fd2df12b4c18.tar.xz
kutter-f1747b51182cbe4d77c991492b55fd2df12b4c18.zip
klippy: Add Python2 module wrappers and use Python3 module naming
Add wrappers for some common Python modules so that the code can run on both Python2 and Python3. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'klippy/extras/statistics.py')
-rw-r--r--klippy/extras/statistics.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/klippy/extras/statistics.py b/klippy/extras/statistics.py
index 641396a3..d9c0a367 100644
--- a/klippy/extras/statistics.py
+++ b/klippy/extras/statistics.py
@@ -23,7 +23,7 @@ class PrinterSysStats:
self.mem_file = None
def stats(self, eventtime):
# Get core usage stats
- ptime = time.clock()
+ ptime = time.process_time()
pdiff = ptime - self.last_process_time
self.last_process_time = ptime
if pdiff > 0.: