refined-addition-53644
12/09/2021, 6:25 PMpython_binary
target from pant v1. Is this same as python_sources
or python_distribution
?
I actually find this documentation more elaborate in terms of python support than v2.
https://v1.pantsbuild.org/python_readme.htmlcurved-television-6568
12/09/2021, 6:27 PMpex_binary
in v2.refined-addition-53644
12/09/2021, 6:29 PMpython_library
in v2?curved-television-6568
12/09/2021, 6:30 PMpython_sources
curved-television-6568
12/09/2021, 6:30 PMcurved-television-6568
12/09/2021, 6:31 PMrefined-addition-53644
12/09/2021, 6:31 PMMaybe it's not supported.BUILD targets make Python code "import-able"python_library
curved-television-6568
12/09/2021, 6:32 PMpython_library
which we also had until recently in v2, where it was renamed to python_sources
.refined-addition-53644
12/09/2021, 6:32 PMpython_sources
generated target?curved-television-6568
12/09/2021, 6:33 PMsrc/pkg/mod/source.py
Then in src/pkg/mod/BUILD
a python_sources
, you can then import your source.py
as import pkg.mod.source
from other modules.curved-television-6568
12/09/2021, 6:34 PM__init__.py
files along the way.. and source roots properly configured.)refined-addition-53644
12/09/2021, 6:36 PMhappy-kitchen-89482
12/09/2021, 8:43 PMpython_sources
is what used to be called python_library
happy-kitchen-89482
12/09/2021, 8:43 PMhappy-kitchen-89482
12/09/2021, 8:44 PMhappy-kitchen-89482
12/09/2021, 8:44 PM__init__.py
, those are necessary only where Python itself deems them necessaryhappy-kitchen-89482
12/09/2021, 8:45 PMhappy-kitchen-89482
12/09/2021, 8:46 PMrefined-addition-53644
12/09/2021, 9:15 PM