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

Stop watching and building Rmd if server is stopped #488

Merged
merged 2 commits into from
Oct 8, 2020

Conversation

cderv
Copy link
Collaborator

@cderv cderv commented Oct 8, 2020

This will fix when the of behavior observed in #481

I believe we should stop watching for modification and auto building Rmd is server has been stopped by the user, using server_stop()

opts$get("served_dirs") seems the right option to check. However, that require setting the first value earlier the first time, that is not in on.exit. Is it safe to modify this ? Seems like the change does the same as before while using okay = FALSE, then okay = TRUE

If not, we could also use opts$get("pids") which is set to NULL in stop_server or another option if necessary.

Feel free to change if that is not okay

Copy link
Member

@yihui yihui left a comment

Choose a reason for hiding this comment

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

Perfect. Thanks!

@yihui yihui merged commit 6806396 into master Oct 8, 2020
@cderv cderv deleted the unwatch-when-stopped branch October 8, 2020 16:26
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.

2 participants