Hacker News new | ask | show | jobs
by devxpy 2813 days ago
Yeah distribution is a _huge_ problem for python right now.
1 comments

Is it though? I mean, yes there is fragmentation and lots of old documentation but that's because Python is 25 years old and several approaches have been tried.

What's especially difficult about the following two steps?

  pip install pyinstaller
  pyinstaller main.py
The main problem isn't the solutions and efforts don't exist, but that core python doesn't care about it.

The core devs don't acknowledge distribution as a real issue -- which makes for a mediocre distribution experience.

Pyinstaller looks great like that, but gets extremely complex for anything serious.

There is another interesting approach on the horizon: https://github.com/Nuitka/Nuitka

Nuitka compiles your Python code to C and leaves you with a single file binary. It also improves performance.

Ubuntu 18.04, Miniconda 3.6 with Numpy etc. I tried Nuitka on my own project, it kept spinning for 20 minutes compiling Numpy dependencies. I eventually gave up and killed the process.
> pyinstaller main.py

One issue with PyInstaller is that it doesn't create a proper standalone binary. It either gives you a full directory tree or, with `--onefile`, an archive which self-extracts into such a tree.