[gnome-music/wip/mschraal/prioritypool-v3: 3/4] asyncqueue: Make debug timing more precise




commit 128d353edd68adca7953f1e7f28e630f2598e17f
Author: Marinus Schraal <mschraal gnome org>
Date:   Tue Feb 1 20:50:10 2022 +0100

    asyncqueue: Make debug timing more precise

 gnomemusic/asyncqueue.py | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
---
diff --git a/gnomemusic/asyncqueue.py b/gnomemusic/asyncqueue.py
index 02129b34f..9b39ab6e5 100644
--- a/gnomemusic/asyncqueue.py
+++ b/gnomemusic/asyncqueue.py
@@ -84,7 +84,6 @@ class AsyncQueue(GObject.GObject):
             self._timeout_id = GLib.timeout_add(100, self._dispatch)
 
     def _dispatch(self) -> bool:
-        tick = time.time()
         common_ids = self._common_ids()
 
         while len(self._async_active_pool) < self._max_async:
@@ -111,7 +110,7 @@ class AsyncQueue(GObject.GObject):
 
             self._async_data[async_obj] = (
                 async_obj.connect("finished", self._on_async_finished),
-                tick)
+                time.time())
             async_obj.start(*async_task_args[1:])
 
         return GLib.SOURCE_CONTINUE


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]