bulky-hamburger-96481
08/29/2023, 4:51 PMbroad-processor-92400
08/29/2023, 7:19 PMpants export-codegen path/to:distribution may output it into a subfolder of dist/. (Iām not sure though, so I may be giving you bad advice š
)late-advantage-75311
08/29/2023, 7:55 PMpants --keep-sandboxes=always --no-local-cache package helloworld:py_dist
(in this case I added a python_distribution to example-python and called it helloworld:py_dist). then you'll see something like:
15:51:01.51 [INFO] Preserving local process execution dir /private/var/folders/z4/dvm2try15dg7gl1vcc_6pv140000gn/T/pants-sandbox-WBRGRi for Run setuptools.build_meta:__legacy__ for helloworld:py_dist
15:51:01.79 [INFO] Wrote dist/helloworlddist-1.0.0-py3-none-any.whl
15:51:01.79 [INFO] Wrote dist/helloworlddist-1.0.0.tar.gz
get logged at the end. Then you can look in the sandbox and you will find the generated setup.py.
$ cat /private/var/folders/z4/dvm2try15dg7gl1vcc_6pv140000gn/T/pants-sandbox-WBRGRi/chroot/setup.py
# DO NOT EDIT THIS FILE -- AUTOGENERATED BY PANTS
# Target: helloworld:py_dist
from setuptools import setup
setup(**{
'install_requires': (
'helloworld.translator==0.0.1',
'setuptools<57,>=56.2.0',
'types-setuptools<58,>=56.2.0',
),
'name': 'helloworlddist',
'namespace_packages': (
),
'package_data': {
'helloworld.greet': (
'translations.json',
),
},
'packages': (
'helloworld',
'helloworld.greet',
),
'python_requires': '==3.9.*',
'version': '1.0.0',
})late-advantage-75311
08/29/2023, 7:59 PM$ pants export-codegen helloworld:py_dist
15:57:08.40 [WARN] No codegen files/targets matched. All codegen target types: experimental_wrap_as_python_sources, experimental_wrap_as_resources, file, resourcehappy-kitchen-89482
08/30/2023, 1:22 AMhappy-kitchen-89482
08/30/2023, 1:23 AM