← Back to team overview

mythbuntu-dev team mailing list archive

[Merge] lp:~tgm4883/mythbuntu/mythbuntu-log-grabber into lp:~mythbuntu-dev/mythbuntu/mythbuntu-log-grabber

 

Thomas Mashos has proposed merging lp:~tgm4883/mythbuntu/mythbuntu-log-grabber into lp:~mythbuntu-dev/mythbuntu/mythbuntu-log-grabber.

Requested reviews:
  mythbuntu-dev (mythbuntu-dev)

For more details, see:
https://code.launchpad.net/~tgm4883/mythbuntu/mythbuntu-log-grabber/+merge/101558

Added missing logs new in 0.25
-- 
https://code.launchpad.net/~tgm4883/mythbuntu/mythbuntu-log-grabber/+merge/101558
Your team mythbuntu-dev is requested to review the proposed merge of lp:~tgm4883/mythbuntu/mythbuntu-log-grabber into lp:~mythbuntu-dev/mythbuntu/mythbuntu-log-grabber.
=== modified file 'debian/changelog'
--- debian/changelog	2011-08-31 17:58:13 +0000
+++ debian/changelog	2012-04-11 14:00:32 +0000
@@ -1,3 +1,9 @@
+mythbuntu-log-grabber (0.10-0ubuntu1) UNRELEASED; urgency=low
+
+  * Added new logs for 0.25
+
+ -- Thomas Mashos <thomas@xxxxxxxxxx>  Wed, 11 Apr 2012 06:56:23 -0700
+
 mythbuntu-log-grabber (0.9-0ubuntu2) oneiric; urgency=low
 
   [ Marcin Juszkiewicz ]

=== modified file 'plugins/python/log_grabber.py'
--- plugins/python/log_grabber.py	2011-04-13 18:56:02 +0000
+++ plugins/python/log_grabber.py	2012-04-11 14:00:32 +0000
@@ -240,18 +240,21 @@
         MAXLINES=1000
         MLP=MAXLINES/100
         LINES=MAXLINES+MLP
-        f = open(FILEPATH, "r")
         linestuffs = []
-        more = True
-        while more:
-            line = f.readline()
-            if line:
-                if len(linestuffs) >= LINES:
-                    del linestuffs[0:MLP]
-                linestuffs.append(line)
-            else:
-                more = False
-        f.close()
+        if os.path.isfile(FILEPATH):
+            f = open(FILEPATH, "r")
+            more = True
+            while more:
+                line = f.readline()
+                if line:
+                    if len(linestuffs) >= LINES:
+                        del linestuffs[0:MLP]
+                    linestuffs.append(line)
+                else:
+                    more = False
+            f.close()
+        else:
+            linestuffs.append("** "+FILEPATH+" not found **\n")
         data_in = "=== "+FILEPATH+" ===\n"
         for stuff in linestuffs:
             data_in += stuff ## Change to write to logfile
@@ -280,12 +283,28 @@
         self.tail_log('/var/log/syslog', "Syslog")
 
     def mythfrontend(self):
-        """Read in the Frontend Log"""
+        """Read in the Frontend type logs"""
         self.tail_log('/var/log/mythtv/mythfrontend.log', "Mythfrontend Log")
+        self.tail_log('/var/log/mythtv/mythavtest.log', "Mythavtest Log")
+        self.tail_log('/var/log/mythtv/mythlcdserver.log', "Mythlcdserver Log")
+        self.tail_log('/var/log/mythtv/mythmessage.log', "Mythmessage Log")
+        self.tail_log('/var/log/mythtv/mythshutdown.log', "Mythshutdown Log")
+        self.tail_log('/var/log/mythtv/mythwelcome.log', "Mythwelcome Log")
 
     def mythbackend(self):
-        """Read in the Backend Log"""
+        """Read in the Backend type logs"""
         self.tail_log('/var/log/mythtv/mythbackend.log', "Mythbackend Log")
+        self.tail_log('/var/log/mythtv/mythccextractor.log', "Mythccextractor Log")
+        self.tail_log('/var/log/mythtv/mythcommflag.log', "Mythcommflag Log")
+        self.tail_log('/var/log/mythtv/mythexport.log', "Mythexport Log")
+        self.tail_log('/var/log/mythtv/mythfilldatabase.log', "Mythfilldatabase Log")
+        self.tail_log('/var/log/mythtv/mythjobqueue.log', "Mythjobqueue Log")
+        self.tail_log('/var/log/mythtv/mythmediaserver.log', "Mythmediaserver Log")
+        self.tail_log('/var/log/mythtv/mythmetadatalookup.log', "Mythmetadatalookup Log")
+        self.tail_log('/var/log/mythtv/mythpreviewgen.log', "Mythpreviewgen Log")
+        self.tail_log('/var/log/mythtv/mythtranscode.log', "Mythtranscode Log")
+        self.tail_log('/var/log/mythtv/mythtv-setup.log', "Mythtv-setup Log")
+        self.tail_log('/var/log/mythtv/mythutil.log', "mythutil Log")
 
     def disk_space(self):
         """Gather all Disk Information"""


Follow ups