예제 #1
0
파일: base.py 프로젝트: yarikoptic/qme
 def err(self):
     """Return error stream. Returns empty string if empty or doesn't exist.
        Returns (str) : error stream written to file
     """
     if os.path.exists(self.stderr.name):
         return read_file(self.stderr.name)
     return ""
예제 #2
0
 def action_get_output(self, data):
     """Get error stream, if the file exists.
     """
     outputfile = data.get("outputfile")
     if os.path.exists(outputfile):
         return read_file(outputfile)
     return ["%s does not exist.\n" % outputfile]
예제 #3
0
파일: base.py 프로젝트: yarikoptic/qme
 def out(self):
     """Return output stream. Returns empty string if empty or doesn't exist.
        Returns (str) : output stream written to file
     """
     if os.path.exists(self.stdout.name):
         return read_file(self.stdout.name)
     return ""
예제 #4
0
 def action_get_error(self, data):
     """Get just output stream, if the file exists.
     """
     errorfile = data.get("outputfile")
     if os.path.exists(errorfile):
         return read_file(errorfile)
     return ["%s does not exist.\n" % errorfile]