title: Python parsing log file to extract events in real time
body: <p>I've a process that is logging messages to a file. </p>
  
  <p>I want to implement another process (in Python) that parses these logs (as they are written to the file), filters the lines that I'm interested in and then  performs certain actions based on the state of the first process.</p>
  
  <p>I was wondering before I go ahead and write something on my own if there is a library in Python that does something like this. </p>
  
  <p>Also, ideas regarding how implement something like this Python would be appreciated. </p>
  
  <p>Thanks. </p>