[pitivi: 16/28] Report a more descriptive error in ElementTreeFormatter._discovererDiscoveryErrorCb



commit eb49bcc4fa4da47f22587791be55b115d39f004f
Author: Alex BÄluÈ <alexandru balut gmail com>
Date:   Thu Jul 7 22:44:58 2011 +0200

    Report a more descriptive error in ElementTreeFormatter._discovererDiscoveryErrorCb

 pitivi/formatters/etree.py |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/pitivi/formatters/etree.py b/pitivi/formatters/etree.py
index a87908b..7b14818 100644
--- a/pitivi/formatters/etree.py
+++ b/pitivi/formatters/etree.py
@@ -832,8 +832,12 @@ class ElementTreeFormatter(Formatter):
             # someone else is using discoverer, this signal isn't for us
             return
 
-        self.emit("new-project-failed", project_uri,
-                FormatterError("%s: %s" % (error, detail)))
+        message = _("Failed loading %(uri)s.") % {"uri": uri}
+        message += "\n\n%s" % error
+        if detail:
+            message += "\n\n%s" % detail
+        formatter_error = FormatterError(message)
+        self.emit("new-project-failed", project_uri, formatter_error)
 
     def newProject(self):
         project = Formatter.newProject(self)



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