def detect_played_audio_in_PMS_log(self): if not os.path.isfile(self.config.get('plex-scrobble', 'mediaserver_log_location')): self._output(hints='Log file does not exist, please ensure you have' 'correctly set mediaserver_log location in your Plex Scrobbler' 'configuration.') return with open(self.config.get('plex-scrobble', 'mediaserver_log_location')) as fh: for line in fh: played = parse_line(line) if played: self._output() return self._output(hints='Unable to detect any instances of audio files played' ' in your plex media server log file. Please ensure you have listened to' ' a song in full and you have enabled Plex to log in DEBUG mode.')
def setUp(self): with io.open('data/universal_transcode.log', 'r') as fh: self.found = [parse_line(line) for line in fh if parse_line(line)]
def setUp(self): with io.open('data/unicode_pms.log', 'r', encoding='utf-8') as fh: self.found = [parse_line(line) for line in fh if parse_line(line)]
def setUp(self): with open('data/universal_transcode.log', 'r') as fh: self.found = [parse_line(line) for line in fh if parse_line(line)]
def setUp(self): with open('data/unicode_pms.log', 'r') as fh: self.found = [parse_line(line) for line in fh if parse_line(line)]