From 8e22f5c4325362dc234f58a30af6b7d0e61d3848 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 20 Jun 2011 13:40:04 -0600 Subject: [PATCH] More device job sequencing debug printouts --- src/calibre/gui2/device.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/calibre/gui2/device.py b/src/calibre/gui2/device.py index 9f6381b859..a527cc2e27 100644 --- a/src/calibre/gui2/device.py +++ b/src/calibre/gui2/device.py @@ -58,10 +58,17 @@ class DeviceJob(BaseJob): # {{{ def job_done(self): self.duration = time.time() - self.start_time self.percent = 1 + if DEBUG: + prints('DeviceJob:', self.id, self.description, + 'done, calling callback', safe_encode=True) + try: self.callback_on_done(self) except: pass + if DEBUG: + prints('DeviceJob:', self.id, self.description, + 'callback returned', safe_encode=True) self.job_manager.changed_queue.put(self) def report_progress(self, percent, msg=''):