← Back to team overview

openlp-core team mailing list archive

[Merge] lp:~googol/openlp/bug-1023522 into lp:openlp

 

Andreas Preikschat has proposed merging lp:~googol/openlp/bug-1023522 into lp:openlp.

Requested reviews:
  OpenLP Core (openlp-core)
Related bugs:
  Bug #1023522 in OpenLP: "OpenLP does not start in debug mode"
  https://bugs.launchpad.net/openlp/+bug/1023522

For more details, see:
https://code.launchpad.net/~googol/openlp/bug-1023522/+merge/114480

fixed bug 1023522 (OpenLP does not start in debug mode)
-- 
https://code.launchpad.net/~googol/openlp/bug-1023522/+merge/114480
Your team OpenLP Core is requested to review the proposed merge of lp:~googol/openlp/bug-1023522 into lp:openlp.
=== modified file 'openlp/core/__init__.py'
--- openlp/core/__init__.py	2012-07-08 22:11:20 +0000
+++ openlp/core/__init__.py	2012-07-11 18:09:21 +0000
@@ -207,6 +207,7 @@
         else:
             return QtGui.QApplication.event(self, event)
 
+
 def set_up_logging(log_path):
     """
     Setup our logging using log_path
@@ -217,6 +218,9 @@
     logfile.setFormatter(logging.Formatter(
         u'%(asctime)s %(name)-55s %(levelname)-8s %(message)s'))
     log.addHandler(logfile)
+    if log.isEnabledFor(logging.DEBUG):
+        print 'Logging to:', filename
+
 
 def main(args=None):
     """
@@ -247,7 +251,6 @@
     qt_args = []
     if options.loglevel.lower() in ['d', 'debug']:
         log.setLevel(logging.DEBUG)
-        print 'Logging to:', filename
     elif options.loglevel.lower() in ['w', 'warning']:
         log.setLevel(logging.WARNING)
     else:


Follow ups