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

Python 0.9.1

25 views
Skip to first unread message

Skip Montanaro

unread,
Feb 16, 2021, 4:57:32 PM2/16/21
to
A note to webm...@python.org from an astute user named Hiromi in
Japan* referred
us to Guido's shell archives for the 0.9.1 release from 1991. As that
wasn't listed in the historical releases README file:

https://legacy.python.org/download/releases/src/README

I pulled the shar files (and a patch), then made a few tweaks to get it to
build:

% ./python
>>> print 'hello world!'
hello world!
>>> import sys
>>> dir(sys)
['argv', 'exit', 'modules', 'path', 'ps1', 'ps2', 'stderr', 'stdin',
'stdout']
>>> sys.modules
{'builtin': <module 'builtin'>; 'sys': <module 'sys'>; '__main__': <module
'__main__'>}
>>> sys.exit(0)

I then pushed the result to a Github repo:

https://github.com/smontanaro/python-0.9.1

There is a new directory named "shar" with the original files, a small
README file and a compile.patch file between the original code and the
runnable code.

It was a pleasant diversion for a couple hours. I was tired of shovelling
snow anyway... Thank you, Hiromi.

Skip

* Hiromi is bcc'd on this note in case he cares to comment. I didn't want
to publish his email beyond the bounds of the webmaster alias without his
permission.

Guido van Rossum

unread,
Feb 16, 2021, 5:44:58 PM2/16/21
to
Awesome, Skip!

Was there a date somewhere? I can't recall if this would have been the
first open source release (from just about 30 years ago, sometime in
February 1991) or some time later in the same year?

On Tue, Feb 16, 2021 at 1:57 PM Skip Montanaro <skip.mo...@gmail.com>
wrote:
> _______________________________________________
> Python-Dev mailing list -- pytho...@python.org
> To unsubscribe send an email to python-d...@python.org
> https://mail.python.org/mailman3/lists/python-dev.python.org/
> Message archived at
> https://mail.python.org/archives/list/pytho...@python.org/message/VZYELIYAQWUHHGIIEPPJFREDX6F24KMN/
> Code of Conduct: http://python.org/psf/codeofconduct/
>


--
--Guido van Rossum (python.org/~guido)
*Pronouns: he/him **(why is my pronoun here?)*
<http://feministing.com/2015/02/03/how-using-they-as-a-singular-pronoun-can-change-the-world/>

Mats Wichmann

unread,
Feb 16, 2021, 6:14:47 PM2/16/21
to
On 2/16/21 3:44 PM, Guido van Rossum wrote:
> Awesome, Skip!
>
> Was there a date somewhere? I can't recall if this would have been the
> first open source release (from just about 30 years ago, sometime in
> February 1991) or some time later in the same year?

Guido van Rossum
unread,
Python 0.9.1 part 01/21
XThis is Python, an extensible interpreted programming language that
Xcombines remarkable power with very clear syntax. X XThis is version
0.9 (the first beta release), patchlevel
2/19/91

Guido van Rossum

unread,
Feb 16, 2021, 6:18:10 PM2/16/21
to
On Tue, Feb 16, 2021 at 2:59 PM Senthil Kumaran <sen...@uthcode.com> wrote:

> On Tue, Feb 16, 2021 at 1:58 PM Skip Montanaro <skip.mo...@gmail.com>
> wrote:
>
>>
>> I then pushed the result to a Github repo:
>>
>> https://github.com/smontanaro/python-0.9.1
>>
>
> Wow. Was white-space not significant in this release of Python? I see the
> lack of indentation in the first Python programs.
>

Indentation most certainly was significant from day 0. I suspect what
happened is that these files got busted somehow by the extraction process
used by Skip or Hiromi.

Skip Montanaro

unread,
Feb 16, 2021, 6:49:23 PM2/16/21
to
>
> Wow. Was white-space not significant in this release of Python? I see the
>> lack of indentation in the first Python programs.
>>
>
> Indentation most certainly was significant from day 0. I suspect what
> happened is that these files got busted somehow by the extraction process
> used by Skip or Hiromi.
>

Yes, that's certainly possible. While it's nice that Google has archived
this stuff, their faithfulness to the original formats leaves a bit to be
desired (and gmane still doesn't work for me, eliminating that option). Guido's
messages are displayed as HTML, and I saw no way to get at the raw Usenet
messages. I just copied the shar data and saved the result. It seems clear
that tabs copied as spaces. The Makefile indentation was hosed up. It
should have dawned on me that the .py, .c and .h files would be messed up
as well. I was only concerned with building the interpreter.

If someone knows how to get the original Usenet messages from what Google
published, let me know.

Skip

>

Skip Montanaro

unread,
Feb 16, 2021, 7:21:33 PM2/16/21
to
> If someone knows how to get the original Usenet messages from what Google published, let me know.

Seems the original shar is there buried in a Javascript string toward
the end of the file. I think I've got a handle on it, though it will
take a Python script to massage back into correct format.

Skip

Skip Montanaro

unread,
Feb 16, 2021, 10:00:33 PM2/16/21
to
> Also mind
> http://www.dalkescientific.com/writings/diary/archive/2009/03/27/python_0_9_1p1.html
> for result comparison.

Thanks, Paul. I had lost track of Andrew. Good to know he's still out
there. I wonder why his tar file was never sucked up into the
historical releases page.

Whew! My stupid little extraction script did a reasonable job. I see
plenty of differences, but a cursory examination shows they are only
in leading whitespace. Where I translated "\t" to TAB, it seems Andrew
used a suitable number of spaces. Python modules/scripts seem more
plausibly indented, and the couple I tried worked, so I'm a bit more
confident I have things right:

% PYTHONPATH=lib ./src/python
>>> import string
>>> print string.upper('hello world!')
HELLO WORLD!
>>>
% ./src/python lib/fact.py
99999
[3, 3, 41, 271]
4096
[2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2]

The tests don't pass though. 1 * 1 raises an integer overflow exception:

>>> 1 * 1
Unhandled exception: run-time error: integer overflow
Stack backtrace (innermost last):
File "<stdin>", line 1

I'll let someone figure that out. :-)

At any rate, the git repo has been updated.

Skip

Dan Stromberg

unread,
Feb 19, 2021, 1:32:00 AM2/19/21
to
On Thu, Feb 18, 2021 at 9:39 PM David Mertz <me...@gnosis.cx> wrote:

> As Skip pointed out to me privately, there are some minor limitations with
> this version. E.g.:
>
> % python
> >>> import glob
> >>> import sys
> >>> print 'hello'
> hello
> >>> print 2+2
> 4
> >>> print 2*2
> Unhandled exception: run-time error: integer overflow
> Stack backtrace (innermost last):
> File "<stdin>", line 1
>

Huh. I wonder what's different about my build:
$ /usr/local/cpython-0.9/bin/python
below cmd output started 2021 Thu Feb 18 10:24:00 PM PST
>>> 2*2
4
>>> print 2*2
4
>>>

You can download a script to build it and a bunch of other python versions
at https://stromberg.dnsalias.org/~strombrg/cpythons/
It includes all the tarballs you should need, at least for Debian. I
believe I used it on CentOS recently as well. I haven't tried it on Ubuntu
in a while.
It depends on https://stromberg.dnsalias.org/~strombrg/cobble.html - and
I'd like to think that's its only external dependency.

HTH

Christian Gollwitzer

unread,
Feb 19, 2021, 2:08:52 AM2/19/21
to
Am 16.02.21 um 22:57 schrieb Skip Montanaro:
> A note to webm...@python.org from an astute user named Hiromi in
> Japan* referred
> us to Guido's shell archives for the 0.9.1 release from 1991.

> I then pushed the result to a Github repo:
>
> https://github.com/smontanaro/python-0.9.1
>

That's a nice find!

Reading the README, it occured to me that it refers to the shell, awk
and perl as contenders for Python[1], but not to Tcl. I would have
thought that in 1991, Tcl was one of the obvious choices as an extension
language. At that time, it had already progressed to version 6 [2]

Was Guido not aware of Tcl, or did he not think that it is a contender
in the same area?

Christian




[1] "Python, an extensible interpreted programming language [...] can be
used instead of shell, Awk or Perl scripts, to write prototypes of real
applications, or as an extension language of large systems, you name it."

[2] https://wiki.tcl-lang.org/page/Tcl+chronology

0 new messages