Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Bug fixes to OSX FSW - #2140

Merged
jonmill merged 1 commit into
dotnet:masterfrom
jonmill:fsw
Jul 8, 2015
Merged

jonmill merged 1 commit into
dotnet:masterfrom
jonmill:fsw

Conversation

@jonmill

@jonmill jonmill commented Jun 23, 2015

Copy link
Copy Markdown

Fixing bugs in the OSX FileSystemWatcher to make almost all tests pass (minus 3)

@stephentoub @ellismg

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there nothing we can assert here?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The previous assumptions about this assert were incorrect in that we can have a rename without a pair when an item is moved out / in from / to the watcher directory. The current index may be the last item in the array of events, meaning the only thing we could assert is that the index is within the bounds of the array, but we would have other (more fundamental issues) if that ever occurred. I should remove the line though...forgot to do that

@ellismg

ellismg commented Jun 23, 2015

Copy link
Copy Markdown
Contributor

I would rebase and squash 9af76dd into the previous commit for a nicer history.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you help me understand what was going on here before? It seems like now we just disable coalescing from the OS, was the coalescing causing problems?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This value didn't seem to cause a difference in coalescing...the OS still coalesced events as expected. I'm not 100% sure what this value is supposed to affect since changing it to 0 made no noticeable difference; due to that, making it 0 is much more clear that it isn't some magic value

@jonmill

jonmill commented Jun 30, 2015

Copy link
Copy Markdown
Author

@ellismg I'll squash before I put out my final iteration

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your most recent commit updated the comment to include moving out of the watched folder, but it didn't update the implementation accordingly... wouldn't moving out be treated as deletion, not creation?

@jonmill

jonmill commented Jul 8, 2015

Copy link
Copy Markdown
Author

@stephentoub @ellismg updated with squashed version and all tests passing

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@stephentoub Now that I think about it, should this be Path.DirectorySeparatorChar?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ideally, but it's not a big deal in this case, since the file is already specific to OS X.

@jonmill

jonmill commented Jul 8, 2015

Copy link
Copy Markdown
Author

@dotnet-bot test this please

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? Just curious. I had to count the number of Fs to verify it was correct.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just making it exactly what it is in the header file and not having to look up the specific value for MaxValue....it just made it more explicit

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok.

@jonmill

jonmill commented Jul 8, 2015

Copy link
Copy Markdown
Author

@stephentoub @ellismg latest version passing with all comments fixed

@ellismg

ellismg commented Jul 8, 2015

Copy link
Copy Markdown
Contributor

LGTM

@jonmill

jonmill commented Jul 8, 2015

Copy link
Copy Markdown
Author

Thanks all! Merging now

jonmill pushed a commit that referenced this pull request Jul 8, 2015
Fixing bugs in the OS X FileSystemWatcher so all tests pass
@jonmill
jonmill merged commit 67f73d0 into dotnet:master Jul 8, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants