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

error = "trim" #1331

Closed
3 tasks done
wlandau opened this issue Sep 9, 2024 · 1 comment
Closed
3 tasks done

error = "trim" #1331

wlandau opened this issue Sep 9, 2024 · 1 comment
Assignees

Comments

@wlandau
Copy link
Member

wlandau commented Sep 9, 2024

Prework

  • I understand and agree to help guide.
  • I understand and agree to contributing guide.
  • New features take time and effort to create, and they take even more effort to maintain. So if the purpose of the feature is to resolve a struggle you are encountering personally, please consider first posting a "trouble" or "other" issue so we can discuss your use case and search for existing solutions first.

Proposal

Suggested by @hadley in #1310 (comment): if a target fails, then

  1. Don't start anything downstream of that target.
  2. Cancel dynamic branches with the same parent.
  3. Let everything else run.

For (2), there is the question of what we mean by "cancel". When one branch throws an error, some of its siblings may not have started yet, whereas others may already be running. I would prefer to cancel the former and let the latter keep running. Reasons:

  1. It seems friendlier for users and easier for them to understand.
  2. In distributed computing scenarios, it won't require Support for mirai cancellation shikokuchuo/mirai#112 or WISH: Add method for interrupting / terminating a future HenrikBengtsson/future#93. (NB clustermq doesn't support cancellation either AFAIK.)
  3. It's much easier to implement and maintain.
  4. It's more consistent with the rest of targets: error = "trim" will treat currently running targets the exact same way as error = "abridge"

Overall, I think error = "trim" will be a nice addition to targets.

@wlandau wlandau self-assigned this Sep 9, 2024
wlandau-lilly pushed a commit that referenced this issue Sep 9, 2024
@wlandau wlandau mentioned this issue Sep 9, 2024
2 tasks
@wlandau
Copy link
Member Author

wlandau commented Sep 10, 2024

Added in #1332

@wlandau wlandau closed this as completed Sep 10, 2024
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

1 participant