cpython/Lib
Barry Warsaw bfa3f6b673 Several changes:
1. Convert to using re module

2. Added two new exception classes

    a. MissingSectionHeaderError which signals an early parsing
       exception when options appear in the file before any section
       header.  Previously a bogus TypeError was thrown deeper down.

    b. ParsingError which collates any non-fatal parsing errors.
       ConfigParser.read() will raise this after the entire file was
       parsed if any errors occurred during parsing (client could just
       catch the exception and continue, because the ConfigParser
       instance would still be initialized with the valid data).

   (small note: Error.__msg => Error._msg)

3. ConfigParser.__read() now uses re which has the following minor
   semantic change: underscore is now allowed in section header and
   option name.  Also, because of the old regexps, theoretically.
   Fixed continuation line bug reported by F. Lundh.

4. It seemed that the old ConfigParser automatically added the option
   `name' to every section, which contained the name of the section.
   This seemed bogus to me so I took it out.
1998-07-01 20:41:12 +00:00
..
dos-8x3 The usual 1998-04-09 21:47:39 +00:00
lib-old Untabified -- to satisfy the tab nanny. 1998-06-09 19:19:40 +00:00
lib-stdwin Fixed conversion between seconds and milliseconds. 1996-12-12 23:42:20 +00:00
lib-tk Allow binding a Tcl command (given as a string) as well as a Python 1998-06-25 18:54:49 +00:00
plat-aix3 New AIX specific subdirs 1996-08-08 18:24:58 +00:00
plat-aix4 New AIX specific subdirs 1996-08-08 18:24:58 +00:00
plat-freebsd2 New files from Thomas Gellekum 1998-05-06 15:14:36 +00:00
plat-freebsd3 New files from Thomas Gellekum 1998-05-06 15:14:36 +00:00
plat-generic Use fcntl.h instead of sys/fcntl.h; use h2py.py from Tools/scripts 1996-08-08 18:25:40 +00:00
plat-irix5 Mass check-in after untabifying all files that need it. 1998-03-26 20:23:01 +00:00
plat-irix6 Mass check-in after untabifying all files that need it. 1998-03-26 20:23:01 +00:00
plat-linux1 more recent linux header files 1996-01-26 17:43:46 +00:00
plat-linux2 Regenerated on a newer Linux version. 1997-05-09 02:21:06 +00:00
plat-netbsd1 More generated files for netbsd 1.x, by Anders Andersen. 1997-12-03 18:44:57 +00:00
plat-next3 regen for Next 1996-08-16 18:14:41 +00:00
plat-sunos4 Merge alpha100 branch back to main trunk 1994-08-01 11:34:53 +00:00
plat-sunos5 Added stropts.h to the list of files automatically regenerated. 1997-12-02 14:37:20 +00:00
plat-win Added table of WSA error codes. 1998-05-06 13:48:04 +00:00
test Improved test set for int() and long() string conversions. 1998-06-30 17:02:20 +00:00
BaseHTTPServer.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
Bastion.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
CGIHTTPServer.py From: conrad@cgl.ucsf.edu (Conrad Huang %CGL) 1998-05-13 20:13:24 +00:00
ConfigParser.py Several changes: 1998-07-01 20:41:12 +00:00
Makefile Remove .pyo files like .pyc files. 1997-10-20 23:16:58 +00:00
MimeWriter.py Run the self-test (test.test_MimeWriter) when invoked as a script. 1998-04-23 13:34:57 +00:00
Queue.py Replace all calls to acquire_lock() and release_lock() with acquire() 1998-04-29 14:29:32 +00:00
SimpleHTTPServer.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
SocketServer.py Fixed the UDP server -- this never worked. Ray Loyzaga deserves 1998-06-16 02:27:33 +00:00
StringIO.py Patch by Lars Wirzenius to allow f.readline(length). 1997-07-25 14:56:01 +00:00
UserDict.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
UserList.py Add pop method. 1998-06-30 15:40:05 +00:00
aifc.py Small corrections to comments that were cloned from aifc; moreover 1998-04-23 21:40:02 +00:00
anydbm.py Oops, I had 'n' and 'c' mixed up in my mind. Get rid of the comment 1998-04-28 15:23:09 +00:00
audiodev.py Added support for 4-channel on SGI. 1996-12-13 00:19:56 +00:00
base64.py Fixed spelling in comment: "RFC", not "RFX". 1998-05-22 18:18:08 +00:00
bdb.py Use sys.exc_info() where needed. 1997-09-29 23:22:12 +00:00
binhex.py A few lines were indented using spaces instead of tabs -- fix them. 1998-03-26 20:56:10 +00:00
bisect.py A few lines were indented using spaces instead of tabs -- fix them. 1998-03-26 20:56:10 +00:00
builtin.py added builtin b/w compat module. 1993-10-22 14:24:22 +00:00
calendar.py Merge alpha100 branch back to main trunk 1994-08-01 11:34:53 +00:00
cgi.py Treat "HEAD" same as "GET", so that CGI scripts won't fail. 1998-06-25 02:40:17 +00:00
cmd.py Improved by Eric Raymond. 1998-06-29 17:58:55 +00:00
cmp.py fix buffer size 1994-10-09 22:34:40 +00:00
cmpcache.py fix buffer size 1994-10-09 22:34:40 +00:00
code.py Subsume the interact() function in a class. This should make it 1998-06-23 19:31:19 +00:00
colorsys.py New module 'colorsys' implements conversions between different color systems. 1992-09-07 09:41:48 +00:00
commands.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
compileall.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
copy.py A few lines were indented using spaces instead of tabs -- fix them. 1998-03-26 20:56:10 +00:00
copy_reg.py Added some minimal comments and tweaked lay-out a bit. 1997-05-20 18:03:22 +00:00
dbhash.py backward compatible interface for bsddb 1996-01-25 18:33:39 +00:00
dircache.py posix -> os 1992-03-31 18:55:40 +00:00
dircmp.py * Got entirely rid of path.py. 1992-12-14 12:57:56 +00:00
dis.py Added docstrings (contributed by Martin von Loewis). 1997-11-18 15:47:55 +00:00
dospath.py REMOVE samefile(), sameopenfile(), samestat() -- these cannot be made 1998-05-02 00:47:09 +00:00
dumbdbm.py export error == IOError 1996-05-28 22:58:40 +00:00
dump.py New == syntax 1992-01-01 19:35:13 +00:00
exceptions.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
fileinput.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
find.py changes for the Mac 1995-01-27 02:41:45 +00:00
fnmatch.py Convert all remaining *simple* cases of regex usage to re usage. 1997-10-22 21:00:49 +00:00
formatter.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
fpformat.py re -> regex conversions by Sjoerd. 1997-10-24 14:46:16 +00:00
ftplib.py parse150(): Simplify RE used to parse the message a little, taking advantage 1998-04-27 14:39:44 +00:00
getopt.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
getpass.py Don't catch interrupts in getpass() -- the finally clause will reset 1998-06-12 14:28:38 +00:00
glob.py Convert all remaining *simple* cases of regex usage to re usage. 1997-10-22 21:00:49 +00:00
gopherlib.py A few lines were indented using spaces instead of tabs -- fix them. 1998-03-26 20:56:10 +00:00
grep.py Added pgrep() function, which is like grep/egrep/emgrep but uses Perl 1997-10-22 20:44:58 +00:00
gzip.py Fix bug reported by Harri Pasanen: gzip + cPickle doesn't work. The 1998-05-13 21:49:58 +00:00
htmlentitydefs.py added &quot def 1996-05-28 23:18:55 +00:00
htmllib.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
httplib.py Patch by Tim O'Malley for servers that send a response looking just like 1998-01-19 22:25:24 +00:00
ihooks.py Support loading of packages. (I had this coded up for a while but 1998-06-29 20:31:16 +00:00
imaplib.py Piers' latest version, labeled 2.11. This time he integrated my 1998-06-25 02:22:16 +00:00
imghdr.py Allow open file as parameter (must be seekable) (Jack) 1997-10-08 15:22:32 +00:00
keyword.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
knee.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
linecache.py don't print Cannot open/stat messages 1995-08-10 19:32:22 +00:00
locale.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
macpath.py Instead of 'import mac', use 'import os' -- this way, the path syntax 1998-03-03 21:49:01 +00:00
macstat.py * Lib/linecache.py: don't crash on empty filename 1994-08-23 13:32:20 +00:00
macurl2path.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
mailbox.py In class _Subfile, make sure read(n) can't read beyond EOF. Also 1998-06-17 18:34:40 +00:00
mailcap.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
mhlib.py "if match(x) >= 0:" smells of regex matching; should use "if match(x):" 1998-06-23 14:43:06 +00:00
mimetools.py Use random instead of whrandom. 1998-05-20 17:05:52 +00:00
mimetypes.py knownfiles: Add the default installation dirs for Apache 1998-05-21 13:15:45 +00:00
mimify.py Sjoerd writes: When a multipart message is incomplete, mimify crashes. 1998-02-27 14:40:38 +00:00
multifile.py # Make tabnanny happy. 1998-06-29 17:58:43 +00:00
mutex.py Change to always call list.append with a single argument. 1996-10-08 14:06:17 +00:00
newimp.py Official version 1.26 directly from Ken 1995-07-12 15:34:34 +00:00
nntplib.py Fix the comments describing the return values of the head(), body(), 1998-06-30 14:50:26 +00:00
ntpath.py REMOVE samefile(), sameopenfile(), samestat() -- these cannot be made 1998-05-02 00:47:09 +00:00
nturl2path.py Allow paths without drive specifier (Jack). 1997-08-12 14:47:24 +00:00
os.py introduce a new platform-specific variable: os.linesep is the 1998-05-22 15:26:04 +00:00
packmail.py Put quotes around the filename, so spaces in filenames work. 1998-04-28 16:03:03 +00:00
pdb.doc Merge alpha100 branch back to main trunk 1994-08-01 11:34:53 +00:00
pdb.py A working version of the 'args' command (it prints the current values 1998-02-25 20:50:32 +00:00
persist.py * ftplib.py: added abort() command (sends oob data). 1993-05-24 14:16:22 +00:00
pickle.py add handler for JPython's org.python.core.PyStringMap object, which 1998-05-27 22:38:22 +00:00
pipes.py Convert all remaining *simple* cases of regex usage to re usage. 1997-10-22 21:00:49 +00:00
poly.py fix bug in poly.minus 1994-10-20 22:02:03 +00:00
popen2.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
poplib.py Version with docstrings and some other changes, by Piers Lauder. 1998-04-09 13:50:55 +00:00
posixfile.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
posixpath.py Added doc strings and reindented according to new standard, without tabs. 1997-12-05 19:04:51 +00:00
pprint.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
profile.doc Merge alpha100 branch back to main trunk 1994-08-01 11:34:53 +00:00
profile.py A few lines were indented using spaces instead of tabs -- fix them. 1998-03-26 20:56:10 +00:00
pstats.py Give in to Timmy's Tedious Tab Theorem. 1998-03-23 15:31:22 +00:00
pty.py New tty/pty modules by Steen; new urlparser. 1994-09-12 10:36:35 +00:00
py_compile.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
pyclbr.py re -> regex conversions by Sjoerd. 1997-10-24 14:46:16 +00:00
quopri.py A few lines were indented using spaces instead of tabs -- fix them. 1998-03-26 20:56:10 +00:00
random.py Make gauss() semi-thread-safe. It can still give duplicate results, 1998-05-29 17:51:31 +00:00
re.py Added findall() to RegexObject -- return a list of all matches in a 1998-06-29 20:29:08 +00:00
reconvert.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
regex_syntax.py Added "new" symbol defns for RE_ANSI_HEX and RE_NO_GNU_EXTENSIONS -- 1997-10-22 16:28:53 +00:00
regsub.py Store the current regex syntax along with the regular expression 1997-02-18 18:52:55 +00:00
repr.py use getattr() instead of eval(), fix string representations 1995-01-12 12:29:17 +00:00
rexec.py For completeness, add a dummy load_package() method to RHooks. It 1998-06-29 20:32:57 +00:00
rfc822.py Bugfix to ESR's code reported by himself: should use hasattr() to test 1998-06-22 15:46:26 +00:00
rlcompleter.py In completer(), return None instead of raising an IndexError when 1998-06-12 19:42:14 +00:00
robotparser.py Give in to tabnanny 1998-04-06 14:29:28 +00:00
sched.py Merge alpha100 branch back to main trunk 1994-08-01 11:34:53 +00:00
sgmllib.py Patch by Lars Marius Garshol: 1998-05-28 22:48:53 +00:00
shelve.py Give in to tabnanny. 1998-04-06 14:14:25 +00:00
shutil.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
site.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
smtplib.py Eric Raymond added support for ESMTP protocol and corrected some typos 1998-06-25 02:15:50 +00:00
sndhdr.py sndhdr.py: restored lost file; audiodev.py: import platform specific 1994-01-14 16:46:14 +00:00
stat.py * Lib/linecache.py: don't crash on empty filename 1994-08-23 13:32:20 +00:00
statcache.py Use global statement instead of importing ourselves to get to global 1995-12-07 10:16:45 +00:00
string.py As Tim Peters points out, ``from string import *'' should not set re to None. 1998-04-20 14:01:00 +00:00
stringold.py As Tim Peters points out, ``from string import *'' should not set re to None. 1998-04-20 14:01:00 +00:00
sunau.py Small corrections to comments that were cloned from aifc; moreover 1998-04-23 21:40:02 +00:00
sunaudio.py Remove reference to obsolete module 'audio' 1992-06-03 16:47:49 +00:00
symbol.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
tabnanny.py From: "Tim Peters" <tim_one@msn.com> 1998-06-09 19:02:21 +00:00
telnetlib.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
tempfile.py On the Mac, create the Temporary Items folder if it does not exist yet. 1998-04-28 16:03:34 +00:00
threading.py Get rid of tabnanny's last complaints. 1998-06-09 19:04:26 +00:00
threading_api.py New Java-style threading module. The doc strings are in a separate module. 1998-04-09 22:01:42 +00:00
toaiff.py * Mass change: get rid of all init() methods, in favor of __init__() 1993-12-17 15:25:27 +00:00
token.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
tokenize.py Differentiate between NEWLINE token (an official newline) and NL token 1998-04-03 16:05:38 +00:00
traceback.py Add obvious needed else clause to format_exception(). 1998-03-18 17:48:06 +00:00
tty.py New tty/pty modules by Steen; new urlparser. 1994-09-12 10:36:35 +00:00
types.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
tzparse.py Convert all remaining *simple* cases of regex usage to re usage. 1997-10-22 21:00:49 +00:00
urllib.py Oops! Of course, Tim is right -- when the item is not a hex number, 1998-06-29 00:42:54 +00:00
urlopen.py urlopen: add basejoin() function. 1994-03-07 11:45:36 +00:00
urlparse.py Add Gopher to list of protocols that support query strings. 1998-01-19 22:27:21 +00:00
user.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
util.py Clarify comment. 1991-04-21 19:34:48 +00:00
uu.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
wave.py Small corrections to comments that were cloned from aifc; moreover 1998-04-23 21:40:02 +00:00
whatsound.py Turns out whatsound.py and sndhdr.py were identical modules. 1997-10-04 20:29:17 +00:00
whichdb.py Support byte-swapped dbhash (bsddb) files. Found by Ben Sayer. 1998-04-28 15:41:03 +00:00
whrandom.py Add comments explaining thread unsafety of this code. 1998-05-29 17:51:59 +00:00
xdrlib.py Mass check-in after untabifying all files that need it. 1998-03-26 21:13:24 +00:00
xmllib.py Sjoerd's latest. 1998-04-03 16:02:39 +00:00
zmod.py New == syntax 1992-01-01 19:35:13 +00:00