Documentation suggestions

Ben Sizer kylotan at gmail.com
Thu Dec 8 04:27:56 EST 2005


rurpy at yahoo.com wrote:
> s... at pobox.com wrote:
> > I suspect I'd have a harder time living without the sys module than with
> > many of the builtins.  Then there's os, re, math, ...  Some modules, like
> > thread and sys, have to be linked into the interpreter.  Are they "core" or
> > "add on"?  Once you start migrating stuff from the "add on" manual (Library
> > Reference) to the "core" manual (Language Reference), where do you stop?
>
> I think a natural dividing line is "import".  If you import it, it
> is in the Library refrence.

Exactly. I'm surprised this is even open to debate. Any built-in which
will work without an import statement - no matter how it's implemented
- should be documented as if it was part of the core language. And
anything you have to explicitly ask for using import, should be in the
library reference under the name of the module or package you're
importing. In terms of knowing where to look for information on a
feature, this is the most sensible approach. In no other language would
I look to the library reference for something which does not appear on
the surface to come from a library.

As an aside, personally I rarely touch the sys module. I use re,
random, threading, and even xml.dom.minidom more than sys.

-- 
Ben Sizer




More information about the Python-list mailing list