Skip to content

./pants dependees should be deprecated in favor of a "root selection" option #6501

@stuhood

Description

@stuhood

./pants changed and ./pants list-owners were converted away from being pants goals and toward being "root selection" options, and we should likely do the same for dependees.

So:

# rather than...
./pants dependees --transitive $target
# ...you'd run something like
./pants --dependees=transitive list $target

There are a few reasons for this:

  1. it's more flexible, because you could use it with other goals: ie: ./pants --dependees=direct test $target.
  2. there is a possible alignment-with/replacement-for the --changed-include-dependees flag, which represents a parallel implementation of the concept in TargetRootsCalculator
  3. it would be cacheable in pantsd sooner than if we ported ./pants dependees into a --v2 task (as in this sketch)

One open question though is whether the --dependees option would include/exclude the original roots. That might also affect naming: if modeled after --changed-include-dependees, it might be a ternary option:

--changed-include-dependees=<str> (one of: [none, direct, transitive] default: 'none')

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions