diff --git a/lib/tfw/components/history_monitor.py b/lib/tfw/components/history_monitor.py index f0c2873..553d6bb 100644 --- a/lib/tfw/components/history_monitor.py +++ b/lib/tfw/components/history_monitor.py @@ -1,6 +1,5 @@ from watchdog.observers import Observer from watchdog.events import FileSystemEventHandler -from collections import deque from os.path import dirname @@ -17,7 +16,7 @@ class CallbackEventHandler(FileSystemEventHandler): class HistoryMonitor: def __init__(self, histfile): self.histfile = histfile - self._history = deque() + self._history = [] self.observer = Observer() self.observer.schedule(CallbackEventHandler(self._fetch_history), dirname(self.histfile)) @@ -27,7 +26,7 @@ class HistoryMonitor: def _fetch_history(self): with open(self.histfile, 'r') as ifile: - self._history = deque(ifile.readlines()) + self._history = ifile.readlines() def watch(self): self.observer.start()