<s> import logging <EOL> import os <EOL> import sys <EOL> from sparts . vservice import VService <EOL> class AtcdVService ( VService ) : <EOL> def initLogging ( self ) : <EOL> super ( AtcdVService , self ) . initLogging ( ) <EOL> sh = logging . handlers . SysLogHandler ( address = self . _syslog_address ( ) ) <EOL> sh . setLevel ( logging . DEBUG ) <EOL> self . logger . addHandler ( sh ) <EOL> sparts_tasks_logger = logging . getLogger ( '<STR_LIT>' ) <EOL> sparts_tasks_logger . addHandler ( sh ) <EOL> def _syslog_address ( self ) : <EOL> address = None <EOL> if sys . platform == '<STR_LIT>' : <EOL> address = '<STR_LIT>' <EOL> elif sys . platform == '<STR_LIT>' : <EOL> address = '<STR_LIT>' <EOL> if address is None or not os . path . exists ( address ) : <EOL> address = ( '<STR_LIT:localhost>' , <NUM_LIT> ) <EOL> return address </s>
