Description
Describe the bug
There's a few "JVM shading rules" (and similar types) that set help
as instructed by their ABC:
pants/src/python/pants/jvm/target_types.py
Lines 602 to 614 in ec86d19
However, it seems like this isn't hooked up right: these rules are BUILD file symbols and the help isn't obeyed: for instance, for
pants/src/python/pants/jvm/target_types.py
Lines 693 to 695 in ec86d19
PANTS_VERSION=2.22.0.dev3 pants --backend-packages=pants.backend.experimental.java help shading_zap
`shading_zap` BUILD file symbol
-------------------------------
Signature: shading_zap(pattern: 'str') -> None
JvmShadingZapRule(pattern: 'str')
The default JvmShadingZapRule(...)
text appears to just be reiterating the dataclass definition.
I think these BUILD file symbols use the doc string, not help
, so potentially the example above should be formatted as something like this:
class JvmShadingZapRule(JvmShadingRule):
"Removes from the final artifact the occurrences of the `pattern`."
alias = "shading_zap"
This appears to affect:
shading_keep
shading_relocate
shading_rename
shading_zap
duplicate_rule
jvm_exclude
scala_exclude
(The last three aren't JvmShadingRule
subclasses but follow a similar pattern.)
Pants version
2.22.0.dev3
OS
both
Additional info
- Will appear in online docs too after Add reference docs for BUILD file symbols pantsbuild.org#216
- Relevant issues:
Activity