Discussion:
Python kit
(too old to reply)
saito
2024-11-22 18:15:30 UTC
Permalink
Is there something in the Python world that is similar to a tclkit? A
minimal run-time environment that ideally consists of a single file? I
was going to post it to the python group but I am not sure I can
properly explain the concept and do it justice.
Christian Gollwitzer
2024-11-22 19:46:49 UTC
Permalink
Post by saito
Is there something in the Python world that is similar to a tclkit? A
minimal run-time environment that ideally consists of a single file? I
was going to post it to the python group but I am not sure I can
properly explain the concept and do it justice.
There is no canonical solution but several possibilities.

There is "pyinstaller" which similarly can create a single-file
executable embedding an arbitrary script. It comes with a static
analyzer which tries to automatically download/package the dependencies.
Problem is the maintenance of it, it used to be a hobby project.

You can also package up a Python script as a zip file, and run this
directly from a python interpreter. I believe the zipkit facility of Tcl
9 is inspired by it. Contrary to pyinstaller, the zip solution cannot
load binary extensions.

Another one is py2exe, which, I think, only runs on Windows.

In my humble experience, the Tclkit solution is more solid than the
Python solutions, in that it doesn't break as easily when you update
some of the dependencies. For pyinstaller, I always had to tweak the
configuration script a little when the libraries have changed (I'm using
matplotlib, which is a HUGE library). OTOH the automatic dependency
resolution is a very nice feature, especially considering the vast
Python library ecosystem.

Christian
saito
2024-11-23 00:53:02 UTC
Permalink
Post by Christian Gollwitzer
Post by saito
Is there something in the Python world that is similar to a tclkit? A
minimal run-time environment that ideally consists of a single file? I
was going to post it to the python group but I am not sure I can
properly explain the concept and do it justice.
There is no canonical solution but several possibilities.
Thank you so very much for the comprehensive reply.
Uwe Schmitz
2024-11-25 11:09:02 UTC
Permalink
Is there something in the Python world that is similar to a tclkit? A minimal run-time environment that ideally consists of a single file? I was going to post it to the python group but I am not sure I can properly explain the concept and do it justice.
I remember using Nuitka (https://nuitka.net/) some time ago.
And I was quite impressed. It appears to be actively maintained.
saito
2024-11-25 18:46:21 UTC
Permalink
Post by Uwe Schmitz
I remember using Nuitka (https://nuitka.net/) some time ago.
And I was quite impressed. It appears to be actively maintained.
Thanks! This looks nice.
Olivier
2024-11-26 16:49:05 UTC
Permalink
saito <***@gmail.com> posted:

From there https://github.com/amykyta3/tclpython/

it is said "This package allows the execution of Python code from a Tcl interpreter".

Is'nt there a Tcl interpreter inside a Tclkit ? It could work ?

Olivier.
Post by saito
Is there something in the Python world that is similar to a tclkit? A
minimal run-time environment that ideally consists of a single file? I
was going to post it to the python group but I am not sure I can
properly explain the concept and do it justice.
Loading...