Skip to content

Conversation

@xzava
Copy link

@xzava xzava commented Jan 19, 2021

Due to blocking their is a delay between when FileSystemEvent obj is created and when the FileSystemEventHandler processed the event. Is means you could only collect the time the event was handled, rather than the time it the event was created.

Events are processed one by one so any blocking on the FileSystemEventHandler affects the time.

So I added 'event_time' property to FileSystemEvent base class to accurately log the time the event was created.

>>> event
<FileModifiedEvent: event_type=modified, src_path='./watch2.py', is_directory=False, event_time=2021-01-19T12:51:29.821598>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant