[Python-Dev] Adding Optik to 2.3 standard library (original) (raw)

Fred L. Drake, Jr. fdrake@acm.org
Fri, 12 Apr 2002 23:14:26 -0400


Barry A. Warsaw writes:

Yes. Move getopt.py to getopt/_getopt.py and put this in getopt/init.py:

Actually, I'd call getopt.py getopt/classic.py, but that's just me. ;)

For backwards compatibility

from _getopt import getopt, error, GetoptError

For convenience

from OptionParser import OptionParser

so some such similar incantation (I don't remember off-hand whether the module names should be fully-qualified or not).

Either should be fine, but we've been recommending full package names for general use, so I think using that would be good form.

-Fred

-- Fred L. Drake, Jr. PythonLabs at Zope Corporation