Did I find the right examples for you? yes no

All Samples(73)  |  Call(31)  |  Derive(30)  |  Import(12)
Log observer that writes to a file-like object.

@type timeFormat: C{str} or C{NoneType}
@ivar timeFormat: If not C{None}, the format string passed to strftime().

src/t/w/twisted-network-programming-essentials-examples-HEAD/Chapter7-Logging/log_colorizer.py   twisted-network-programming-essentials-examples(Download)
import sys
 
from twisted.python.log import FileLogObserver
 
class ColorizedLogObserver(FileLogObserver):

src/z/o/zope.app.twisted-3.5.0/src/twisted/trial/runner.py   zope.app.twisted(Download)
            logFile = file(self.logfile, 'a')
        self._logFileObject = logFile
        self._logFileObserver = log.FileLogObserver(logFile)
        log.startLoggingWithObserver(self._logFileObserver.emit, 0)
 

src/o/h/oh-mainline-HEAD/vendor/packages/twisted/twisted/trial/runner.py   oh-mainline(Download)
            logFile = file(self.logfile, 'a')
        self._logFileObject = logFile
        self._logFileObserver = log.FileLogObserver(logFile)
        log.startLoggingWithObserver(self._logFileObserver.emit, 0)
 

src/h/o/hortonworks-sandbox-HEAD/desktop/core/ext-py/Twisted/twisted/trial/runner.py   hortonworks-sandbox(Download)
            logFile = file(self.logfile, 'a')
        self._logFileObject = logFile
        self._logFileObserver = log.FileLogObserver(logFile)
        log.startLoggingWithObserver(self._logFileObserver.emit, 0)
 

src/m/y/mythbox-HEAD/resources/lib/twisted/twisted/trial/runner.py   mythbox(Download)
            logFile = file(self.logfile, 'a')
        self._logFileObject = logFile
        self._logFileObserver = log.FileLogObserver(logFile)
        log.startLoggingWithObserver(self._logFileObserver.emit, 0)
 

src/t/w/twice-HEAD/twice.py   twice(Download)
    def setup_log(self, name):       
        try: 
            self.log_file = open(name, 'a')
            self.log_observer = log.FileLogObserver(self.log_file)
            log.startLoggingWithObserver(self.log_observer.emit)

src/o/o/ooniprobe-1.0.1/ooni/utils/log.py   ooniprobe(Download)
class LogWithNoPrefix(txlog.FileLogObserver):
    def emit(self, eventDict):
        text = txlog.textFromEventDict(eventDict)
        if text is None:
            return
                                                     otime.utcPrettyDateNow()))
 
        self.fileObserver = txlog.FileLogObserver(daily_logfile)
        self.stdoutObserver = LogWithNoPrefix(sys.stdout)
 

src/s/u/SubliminalCollaborator-HEAD/libs/twisted/trial/runner.py   SubliminalCollaborator(Download)
            logFile = file(self.logfile, 'a')
        self._logFileObject = logFile
        self._logFileObserver = log.FileLogObserver(logFile)
        log.startLoggingWithObserver(self._logFileObserver.emit, 0)
 

src/o/o/ooni-probe-HEAD/ooni/utils/log.py   ooni-probe(Download)
class LogWithNoPrefix(txlog.FileLogObserver):
    def emit(self, eventDict):
        text = txlog.textFromEventDict(eventDict)
        if text is None:
            return
                                                  otime.utcPrettyDateNow()))
 
        self.fileObserver = txlog.FileLogObserver(daily_logfile)
        self.stdoutObserver = LogWithNoPrefix(sys.stdout)
 

src/t/w/Twisted-13.2.0/twisted/trial/runner.py   Twisted(Download)
            logFile = file(self.logfile, 'a')
        self._logFileObject = logFile
        self._logFileObserver = log.FileLogObserver(logFile)
        log.startLoggingWithObserver(self._logFileObserver.emit, 0)
 

  1 | 2 | 3 | 4 | 5 | 6  Next