Support post-dependencies
- Dominant language
- C#
- Stars
- 4.2k
- Forks
- 778
- Avg merge
- 1h 15m
- Merged PRs (30d)
- 19
Description
Issue #1818 was about reverse dependencies and optional dependencies. However, the way they were implemented doesn't support the use case I need them for. Using the example code from that issue:
Task("A");
Task("B").IsDependentOn("A");
Task("C").IsDependentOn("B").IsDependeeOf("D");
Task("D").IsDependeeOf("E");
RunTarget("D");
I would have expected the task traversal
`D` -> `E`
or changing the final line to run target `C`,
`A` -> `B` -> `C` -> `D` -> `E`
That is, I personally was expecting a sort of `finally` block for tasks, where `.IsDependeeOf(task)` is equivalent to `.Finally(() => {RunTask(task);})`, just like `.IsDependentOn(task)` could be approximated by including `RunTask(task)` in the Does block.
Additionally, pull request #1819 did not add the parameter `required` to the extension methods `IsDependentOn` and `IsDependeeOf`.
Contributor guide
Research direction
Read issue #1818 and pull request #1819 first, then inspect the IsDependentOn and IsDependeeOf extension methods and the task traversal behavior described in the examples. Clarify the required-parameter API and the intended post-dependency ordering before determining the relevant implementation and tests; done means both traversal examples behave as specified.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- build-system
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100