Strong typing implementation for Python

Marko Rauhamaa marko at pacujo.net
Mon Oct 12 06:35:06 EDT 2015


John Michael Lafayette <johnmichaelreedfas at gmail.com>:

> Now that Python has static type checking and support for IDE
> auto-complete (PEP 484?), I beg you to please use it. In your standard
> library, in your production code, in everywhere. I cannot type without
> auto-complete.
>
> I know that sounds ridiculous,

It sure does. Ducktyping is the essence of Python. You are asking Python
to become Java.

> You don't understand because you actually know what all the function
> names are and you don't have to constantly hover over them in
> auto-complete and pull up their documentation to figure out how to use
> them.

I barely remember any of them. That's why I keep Python Standard Library
reference in a browser window whenever I program in Python.

> But I do. And for me, without auto-complete, the learning process goes
> from actively querying the IDE for one documentation after another to
> having to minimize the IDE and Google search for each and every
> function and module that I"m not familiar with. Auto-complete
> literally cuts the learning time by more than half.

Many modern windowing systems let you have more than one window on the
screen at once. My Python editor window occupies 25% of the screen. The
rest of the space goes to a browser, a couple of terminals etc.

You don't need Google to see Python's documentation. Just bookmark

   https://docs.python.org/3/library/

> So please please please use PEP 484 to document all your standard
> library functions. Not for static compilation. Not even for catching
> mistakes caused by bad function input (although I like that). For
> Christ's sake, do it for the auto-complete. I gave up on JavaScript in
> favor of TypeScript for a reason god dammit.

It would appear Python is too small a programming language for the two
of us.


Marko



More information about the Python-list mailing list