Skip to content

Commit

Permalink
Update comment for dag.GetSchedulable
Browse files Browse the repository at this point in the history
The comment still described its return as a map, but in #2909, that was changed
to a `sets.String`. When I happened to stumble across this while looking into
something else, I thought "hey, this should probably be updated to be accurate!"

Signed-off-by: Andrew Bayer <andrew.bayer@gmail.com>
  • Loading branch information
abayer authored and tekton-robot committed Oct 14, 2021
1 parent 74f2de9 commit a159e75
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions pkg/reconciler/pipeline/dag/dag.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,11 +88,11 @@ func Build(tasks Tasks, deps map[string][]string) (*Graph, error) {
return d, nil
}

// GetSchedulable returns a map of PipelineTask that can be scheduled (keyed
// by the name of the PipelineTask) given a list of successfully finished doneTasks.
// It returns tasks which have all dependencies marked as done, and thus can be scheduled. If the
// specified doneTasks are invalid (i.e. if it is indicated that a Task is
// done, but the previous Tasks are not done), an error is returned.
// GetSchedulable returns a set of PipelineTask names that can be scheduled,
// given a list of successfully finished doneTasks. It returns tasks which have
// all dependencies marked as done, and thus can be scheduled. If the specified
// doneTasks are invalid (i.e. if it is indicated that a Task is done, but the
// previous Tasks are not done), an error is returned.
func GetSchedulable(g *Graph, doneTasks ...string) (sets.String, error) {
roots := getRoots(g)
tm := sets.NewString(doneTasks...)
Expand Down

0 comments on commit a159e75

Please sign in to comment.