gmyth-stream/server/0.3/plugins/transcoders/mencoder_lib/mythtv.py
branchtrunk
changeset 726 6431b16e18fb
parent 718 3fbcd3d9b2d1
child 728 6e54ca4a4e9a
     1.1 --- a/gmyth-stream/server/0.3/plugins/transcoders/mencoder_lib/mythtv.py	Tue May 29 21:24:48 2007 +0100
     1.2 +++ b/gmyth-stream/server/0.3/plugins/transcoders/mencoder_lib/mythtv.py	Thu May 31 16:09:47 2007 +0100
     1.3 @@ -54,7 +54,7 @@
     1.4                   self.args["gmyth-cat"]["cfile"]
     1.5                   ]
     1.6      else:
     1.7 -        self.log.error(self.tid, "URI error")
     1.8 +        self.log.error(self.tid, "Error: URI error")
     1.9          return []
    1.10  # _setup_gmythcat
    1.11  
    1.12 @@ -65,7 +65,7 @@
    1.13                                        stderr=subprocess.PIPE,
    1.14                                        close_fds=True)
    1.15      except Exception, e:
    1.16 -        self.log.error(self.tid, "Error executing gmyth-cat: %s" % e)
    1.17 +        self.log.error(self.tid, "Error: gmyth-cat: %s" % e)
    1.18          return False
    1.19  
    1.20      if not self._run_mencoder(input=self.gmyth.stdout,
    1.21 @@ -75,9 +75,10 @@
    1.22      if self.args["gmyth-cat"]["kind"] == "f":
    1.23          try:
    1.24              size = _setup_mythfile(self.gmyth.stderr)
    1.25 -            self.log.debug(self.tid, "Size of file: %s" % size)
    1.26 +            self.log.debug(self.tid, "Info: Size of file: %s" % size)
    1.27          except Exception, e:
    1.28 -            self.log.error(self.tid, "Problems getting size of file: %s" % e)
    1.29 +            self.log.error(self.tid, "Error: Problems getting size of"\
    1.30 +                           " file: %s" % e)
    1.31              return False
    1.32  
    1.33      try:
    1.34 @@ -91,16 +92,15 @@
    1.35              if self.gmyth.stderr in r:
    1.36                  partial = self.gmyth.stderr.read(50).split("\n")[-2]
    1.37                  if partial != "":
    1.38 -                    self.status = utils.progress_bar(self.log,
    1.39 -                                                     int(partial),
    1.40 +                    self.status = utils.progress_bar(int(partial),
    1.41                                                       int(size), 50)
    1.42  
    1.43      except IndexError, e:
    1.44          pass
    1.45      except Exception, e:
    1.46 -        self.log.error(self.tid, "Problems handling data: %s" % e)
    1.47 +        self.log.error(self.tid, "Error: %s" % e)
    1.48          return False
    1.49  
    1.50 -    self.log.info(self.tid, "Finished sending data")
    1.51 +    self.log.info(self.tid, "OK: Done")
    1.52      return True
    1.53  # _start_myth()