Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MacOSX: TextEdit event inconsistence #538

Closed
pablomartinezm opened this issue Feb 21, 2019 · 5 comments
Closed

MacOSX: TextEdit event inconsistence #538

pablomartinezm opened this issue Feb 21, 2019 · 5 comments

Comments

@pablomartinezm
Copy link

pablomartinezm commented Feb 21, 2019

Hi again,

I'm attempting to monitor some TextEdit events on MacOSX and there's an inconsistent event sequence:

  1. Create a file:
<FileCreatedEvent: src_path='/text.txt'>
  1. Edit + Save the file:
<FileMovedEvent: src_path='/text.txt', dest_path='/text.txt.sb-fc8ad3a6-66GHcO'>
<DirModifiedEvent: src_path='/'>
<FileDeletedEvent: src_path='/text.txt.sb-fc8ad3a6-66GHcO'>

So I end up with no file :/

any help?

@BoboTiG
Copy link
Collaborator

BoboTiG commented Jun 11, 2019

Don't you have a FileCreatedEvent at the end?

@samschott
Copy link
Contributor

I have encountered a similar issue. Yes, there is an additional FileCreatedEvent, but for some reason it gets logged before the above three. Here is the output from the LoggingEventHandler while saving changes to "Untitled.txt":

2019-12-10 09:34:50 - Created file: /Untitled.txt
2019-12-10 09:34:50 - Moved file: from /Untitled.txt to /Untitled.txt.sb-b78ef837-68vb68
2019-12-10 09:34:50 - Modified directory: /
2019-12-10 09:34:50 - Deleted file: /Untitled.txt.sb-b78ef837-68vb68
2019-12-10 09:34:50 - Modified directory: /

@BoboTiG
Copy link
Collaborator

BoboTiG commented Jan 23, 2021

@samschott, am I right if I say that recent commits fix that issue and #311?

@samschott
Copy link
Contributor

Yes, this should be fixed now. I am currently working an PR to somewhat improve the handling of coalesced events, as noted in #749 there are still a large number of spurious events, but the actual order is correct now.

@BoboTiG
Copy link
Collaborator

BoboTiG commented Jan 23, 2021

Fixed with #734 and #750.

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

No branches or pull requests

3 participants