Read XML file while it is being written (in Python)
I have to monitor an XML file being written by a tool running all the day. But the XML file is properly completed and closed only at the end of the day. Same constraints as XML stream processing: Parse an incomplete XML file on-the-fly and trigger actions Keep track of the last position within the file to avoid processing it again from the beginning On answer of Need to read XML files as a stream using BeautifulSoup in Python , slezica suggests xml.sax , xml.etree.ElementTree and cElementTree . But no success with my attempts to use xml.etree.ElementTree and cElementTree . There are also xml