Hey guys, we are currently writing some new pants ...
# general
p
Hey guys, we are currently writing some new pants plugins for pants 1.30.x. Inside those plugins we would like to use 3rdparty libraries. How can we install these? We added a BUILD file into the plugin root directory, but it doesnt seem to load the dependency
Copy code
python_library(
  name = 'plugin',
  dependencies=[
    '3rdparty/python:pyhocon',
  ]
)
e
I don't think this is documented anywhere, but the
[GLOBAL] plugins
option is a list of requirement strings. Nominally this is intended for fetching Pants 3rdparty plugin distributions, but it can also just fetch non Pants plugins too. So, although it does not accept target addresses, you can use "pyhocon..." where "pyhocon..." Is the same requirement string you define over in 3rdparty/python:pyhocon. Not ideal, but that should work.
p
ahh, that seems to work! thanks
b
Is this meant to be undocumented, or should it be added somewhere?
e
It probably should be added. The v1 docs are ... I'm not sure how you edit those at this point (https://v1.pantsbuild.org). The 1.30 docs at the new pantsbuild.org are very partial - i.e.: if I were using Pants 1.30 I would never look there.
b
@hundreds-father-404 thoughts?
e
To be clear, it should be added to v2 docs. That just would not have helped @plain-river-51682.
p
yeah, I always directly go to v1. because v2 docs dont help me at all 🙂