Skip to content

Move fixed chunk size polling as a watch option and move it out of server #42542

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

Merged
merged 3 commits into from
Mar 3, 2021

Conversation

sheetalkamat
Copy link
Member

Fixes #41549

@typescript-bot
Copy link
Collaborator

Thanks for the PR! It looks like you've changed the TSServer protocol in some way. Please ensure that any changes here don't break consumers of the current TSServer API. For some extra review, we'll ping @sheetalkamat, @amcasey, @mjbvz, @minestarks for you. Feel free to loop in other consumers/maintainers if necessary

@typescript-bot typescript-bot added Author: Team For Milestone Bug PRs that fix a bug with a specific milestone labels Jan 28, 2021
@sheetalkamat
Copy link
Member Author

sheetalkamat commented Jan 28, 2021

Because this needs protocol change in tsserver, i am marking this for 4.3 instead.
@mjbvz starting 4.3 there will be one more option for WatchFile, WatchDirectory and fallbackPolling

Copy link
Member

@amcasey amcasey left a comment

Choose a reason for hiding this comment

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

I had trouble following the polling code. Happy to review in person if that's easier.

}

polled++;
const fileChanged = onWatchedFileStat(watchedFile, getModifiedTime(host, watchedFile.fileName));
Copy link
Member Author

Choose a reason for hiding this comment

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

This is where actual polling happens. and this is the file that gets counted towards the polling. The code was existing just pulled out to helper so that it can be shared.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Author: Team For Milestone Bug PRs that fix a bug with a specific milestone
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

TSServer doesn't respect watchOptions for watchFile
3 participants