https://pantsbuild.org/ logo
#general
Title
# general
h

happy-pizza-30507

01/31/2022, 3:02 PM
Hi, I wonder how to export dependencies as requirements.txt from a given PEX file. I do see the benefit of embedding deps as one single artifact. But for procedural reasons it's a bit rigid to ship an artifact along with the dependencies in some cases. I hope there is some support in PEX / Pants. Thanks!
f

fresh-cat-90827

01/31/2022, 3:32 PM
hi! 🙂 is it possible that you may instead benefit from using a Python wheel? A wheel would include the Python sources from your project and a specification of the 3rd party requirements. When a wheel is installed, the source code it contains will be installed and the dependencies will be downloaded from the available origins (public or private PyPIs)
h

hundreds-father-404

01/31/2022, 3:50 PM
You can also use this option on
pex_binary
to leave off third-party deps 🙂 https://www.pantsbuild.org/docs/reference-pex_binary#codeinclude_requirementscode
🎯 1
h

high-yak-85899

01/31/2022, 5:44 PM
Has there been any investigation on what produces the quickest docker build times and minimal images? Pex is nice because it's all packaged together, but it seems like what you save in dockerfile simplicity, you could potentially lose in the pex building stage. I've generally seen stuff be fast so not too much of a concern. Mostly just curious.
3 Views