How to package and distribute standalone python project on Windows

UPDATE: thanks to lots of contributed hooks, I would choose pyinstaller these days. I recently had a need to distribute an app written in python as standalone on windows machines. Usual way to do it is to use py2exe(or similar) to generate standalone exe from your python script and then use Inno Setup or NSIS to write an installer for it. As it turned out, py2exe, nuitka and pyinstall were unable to track all dependencies of the project automatically (i....

May 5, 2017 · 3 min · 460 words · Ruslan Kuprieiev

python google protobuf and optional field with empty repeated inside (or the 'has_field = true' analog in python)

So I was searching for something to represent protobufs in a human-readable format. After lots of googling I’ve found that there is a magic built-in module called text_format, which does just what I need - it converts protobufs to/from human readable format, which looks quite similar to JSON. But it is not actually a valid JSON, as JSON-supported types don’t match protobufs, and it has a slightly different format. Pb text is fine for reading, but it has a very limited amount of tools that actually support it....

January 14, 2015 · 2 min · 404 words · Ruslan Kuprieiev