How do I watch a file for changes?
问题 I have a log file being written by another process which I want to watch for changes. Each time a change occurs I\'d like to read the new data in to do some processing on it. What\'s the best way to do this? I was hoping there\'d be some sort of hook from the PyWin32 library. I\'ve found the win32file.FindNextChangeNotification function but have no idea how to ask it to watch a specific file. If anyone\'s done anything like this I\'d be really grateful to hear how... [Edit] I should have