4 ms·
Packaging Python apps is pure hell. npm gets a lot of shit, but Python deserves as much if not more.
by teaearlgraycold 1y ago
Packaging Python apps is pure hell. npm gets a lot of shit, but Python deserves as much if not more.
- dayjah 1y agoI know far too much about python packaging while only knowing a little about it. I agree it’s hell. But I’ve not found many comprehensive packaging solutions that aren’t gnarly in some way. IMHO the Python Packaging community have done an excellent job of producing tools to make packaging easy for folks, especially if you’re using GitHub actions. Check out: https://github.com/pypa/cibuildwheel https://github.com/pypa/cibuildwheel Pypa have an extensive list of GitHub actions for various use cases. I think most of us end up in the “pure hell” because we read the docs on how to build a package instead of using the tools the experts created to hide the chaos. A bit like building a deb by hand is a lot harder than using the tools which do it for you.
- teaearlgraycold 1y agoThat’s fair. I’m also thinking about the sheer size of Python apps that make use of the GPU. I have to imagine a C++ app performing neural network shenanigans would’t be >1GB before downloading weights.
- QuadmasterXLII 1y agoI’ve tried, it is still gigabytes, unless you try to dynamically link to user installed CUDA libraries from c++. Which I don’t recommend.
- teaearlgraycold 1y agoOof
- crabmusket 1y agoSpeaking of which, I didn't realise Node had a built in packaging feature to turn scripts into a single executable: https://nodejs.org/api/single-executable-applications.html https://nodejs.org/api/single-executable-applications.html
- bxdhxhxh 1y agoI was not aware of that feature either, thanks for the heads up In my opinion, bundling the application Payload would be sufficient for interpreted languages like python and JavaScript