Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

About Python Compressed Archive or Binaries

26 views
Skip to first unread message

Sina Mobasheri

unread,
Jan 17, 2022, 10:41:45โ€ฏAM1/17/22
to
Java offers download JDK as Compressed Archive or NodeJS offers download Node as Binaries both give us a compressed file for Linux and windows that we can just unzipped it and put in a custom directory and set some environment variables and start working


I'm aware that Python also have something called Embedded Zip for Windows and nothing like that for Linux as far as I know, and I think this Embedded Zip is not something that the user wants to work with that directly it's for embedding in a C++ application, so it's not the same as options that Java and NodeJS offering


My question is why is Python haven't an option for downloading as Compressed Archive?
Is it's due to a technical issue? political reasons? or is it just simply because nobody has thought of doing it?

Chris Angelico

unread,
Jan 17, 2022, 10:48:13โ€ฏAM1/17/22
to

Chris Angelico

unread,
Jan 17, 2022, 10:49:45โ€ฏAM1/17/22
to
Premature send, oops.

That's already possible: https://docs.python.org/3/library/zipapp.html :)

Alternatively, if you mean the CPython binary itself, then that is
available in a number of formats, so I'm not sure what you're asking
about in that case.

ChrisA

Kirill Ratkin

unread,
Jan 17, 2022, 12:50:14โ€ฏPM1/17/22
to
Hi,

Yes, this is good question for Windows users.

Of course, you can download installer exe-file -> do installation ->
pack directory with python interpreter to zip (for example, or 7z) ->
copy archive file to another place/computer and unpack.

But it will not work out of box because original installer modifies
resources in MZ file and path to stdlib is there.

So just to use interpreter from that archive file you need to open
python.exe file and fix it (in any binary/hex editor).

This simple procedure but ... anyway ... I agree with Sina.

It would be nice to have just zip file with python interpreter (not
executable installer), unpack it anywhere, add pathย  to this 'anywhere'
to PATH, and use it.

Java/DotNet/Go have this option. But python - not.

And question is - why?

Sina Mobasheri

unread,
Jan 17, 2022, 2:11:27โ€ฏPM1/17/22
to
That's exactly what I mean thank you ๐Ÿ‘Œ๐Ÿป๐Ÿš€
________________________________
From: Python-list <python-list-bounces+sinamobasheri=outlo...@python.org> on behalf of Kirill Ratkin <kvra...@yandex.ru>
Sent: Monday, January 17, 2022 9:19:44 PM
To: pytho...@python.org <pytho...@python.org>
Subject: Re: About Python Compressed Archive or Binaries
--
https://mail.python.org/mailman/listinfo/python-list

Eryk Sun

unread,
Jan 18, 2022, 8:48:57โ€ฏAM1/18/22
to
On 1/17/22, Sina Mobasheri <sinamo...@outlook.com> wrote:
>
> I'm aware that Python also have something called Embedded Zip for Windows
> and nothing like that for Linux as far as I know, and I think this Embedded
> Zip is not something that the user wants to work with that directly it's for
> embedding in a C++ application, so it's not the same as options that Java
> and NodeJS offering

Use the NuGet packages:

https://docs.python.org/3/using/windows.html#the-nuget-org-packages

These are zipped archives of Python 3.x.y that can be unpacked and
used anywhere you want.

Christian Heimes

unread,
Jan 18, 2022, 9:58:38โ€ฏAM1/18/22
to
On 17/01/2022 18.49, Kirill Ratkin wrote:
> It would be nice to have just zip file with python interpreter (not
> executable installer), unpack it anywhere, add pathย  to this 'anywhere'
> to PATH, and use it.
>
> Java/DotNet/Go have this option. But python - not.
>
> And question is - why?

Java is developed by Oracle (revenue 49 billion USD)
.NET is developed by Microsoft (revenue 161 billion USD)
Go is developed by Google (revenue of parent company is 182 billion USD)
Python is developed by a bunch of (mostly unpoaid) volunteers under the
umbrella of the PSF (revenue 3.1 million USD).

Do you see a pattern? :)

A distributable binary format for CPython is high on our list. Brett
Cannon, Nathaniel Smith, and I have been discussion a proposal recently.
I landed a bunch of changes in 3.11-dev that are both useful for binary
distribution and for Web Assembly builds. Because all work is done in
our free time, there is only little progress.

Christian

Sina Mobasheri

unread,
Jan 18, 2022, 3:19:54โ€ฏPM1/18/22
to
Thanks I really appreciate that, its time consuming task and take lots of hard work for sure, I was thinking it's technical issue for python that there isn't binary format for it, so I'm happy to hear that we will have that option in the future ๐Ÿ™๐Ÿป๐Ÿš€
________________________________
From: Python-list <python-list-bounces+sinamobasheri=outlo...@python.org> on behalf of Christian Heimes <chri...@python.org>
Sent: Tuesday, January 18, 2022, 18:29
To: pytho...@python.org
Subject: Re: About Python Compressed Archive or Binaries

--
https://mail.python.org/mailman/listinfo/python-list

0 new messages