-
-
Notifications
You must be signed in to change notification settings - Fork 878
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
Add propagate option to knit_exit() #1810
Conversation
2f48ed4
to
34261cd
Compare
Hi @yihui, is there anything else I need to do to help this get merged? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry for the late response! I'd like the propagation to be the default behavior. I'm okay with making this breaking change, since I feel it makes a lot more sense for knit_exit()
to exit the whole process. Thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just simplified the PR and made the breaking change. Will merge after tests pass. Thanks!
@yihui - thanks for reviewing! I quite liked the ability to choose the behavior with the |
Okay. I just added the argument back. Thanks again! |
Thanks! |
When calling
knit_exit()
from within a child document, this child document stops rendering and the parent document continues to render. There are certainly circumstances where this is the desired behavior. However, there are also cases where I'd prefer the entire document to stop rendering immediately.This PR adds a
propagate
option toknit_exit()
. This indicates whether the early termination signal should be propagated from child documents up to the top-level document. The default value (FALSE
) retains existing behavior.