I just noticed, that in the docs for Goals, there’...
# development
I just noticed, that in the docs for Goals, there’s a section with “Related Subsystems”. However, it includes itself as well there. I guess the proper fix would be to simply filter out any goals, and that it would exclude itself and leave just subsystems, as it should.
Every goal has a companion subsystem that configures the goal, so I think that's what you're seeing.
👍 1
Well, the link points at the page I'm at, so something is amiss.. on the phone now, can post link/screenshot when I get back..
Well, most links under “Related subsystem” are indeed to documented subsystems. But the current goal whose doc page I’m reading is always also listed under related subsystems. That’s a little confused.
The roots goal for instance, is an easy example, as there’s just two links under the related subsystems heading: https://www.pantsbuild.org/v2.8/docs/reference-roots
The roots link points to the page I’m already at.
Oh, or do you mean there actually also is a
subsystem, not just a goal. However, that subsystem is not documented.. either way, that link ought to be filtered out in that case… 🙂 (not a high prio issue, of course.. just trying to see if I got it right..)
Hmm, yes, so I think the documentation page for a goal is actually the documentation page for its subsystem, so I think you're right
👌 1
Ah, stumbled upon this again, but for the CLI help output, and there it is addressed properly: https://github.com/pantsbuild/pants/blob/964d9d8ddc167ea498da6d05af626c1252f56687/src/python/pants/help/help_printer.py#L253
Copy code
related_scopes = sorted(set(goal_info.consumed_scopes) - {GLOBAL_SCOPE, goal_info.name})