]> git.ipfire.org Git - thirdparty/Python/cpython.git/log
thirdparty/Python/cpython.git
23 years agobackport of the checkin of revision 2.69 of selectmodule.c
Thomas Heller [Tue, 24 Sep 2002 17:24:25 +0000 (17:24 +0000)] 
backport of the checkin of revision 2.69 of selectmodule.c

On Windows, call WSAGetLastError() to retrieve the error number.

Bugfix candidate, will backport to release22-maint myself.

23 years agoChange version stuff to 2.2.2a0.
Guido van Rossum [Tue, 24 Sep 2002 17:17:38 +0000 (17:17 +0000)] 
Change version stuff to 2.2.2a0.

23 years agoChange the version to 2.2.2a0. (Whether we're going to do a 2.2.2
Guido van Rossum [Tue, 24 Sep 2002 17:14:19 +0000 (17:14 +0000)] 
Change the version to 2.2.2a0.  (Whether we're going to do a 2.2.2
alpha or beta at all isn't clear; but while it's unreleased, I think
a0 is the best indicator we've got.)

23 years agoClarify documentation for PyErr_SetObject() to describe the reference
Fred Drake [Tue, 24 Sep 2002 16:44:56 +0000 (16:44 +0000)] 
Clarify documentation for PyErr_SetObject() to describe the reference
count behavior.

23 years agoBe more careful with the type of the xmlhandlersetter; it takes an
Fred Drake [Tue, 24 Sep 2002 16:25:10 +0000 (16:25 +0000)] 
Be more careful with the type of the xmlhandlersetter; it takes an
XML_Parser, which happens to be a pointer type, not an XML_Parser*.
This generated warnings when compiled with Expat 1.95.5, which no
longer defines XML_Parser to be void*.

23 years agoReplaced this with the 2.3 test_mmap, which contains Windows-specific
Tim Peters [Tue, 24 Sep 2002 16:21:36 +0000 (16:21 +0000)] 
Replaced this with the 2.3 test_mmap, which contains Windows-specific
fixes for the "try to resize it" test (Windows grows the underlying
file then, and that screws up later tests that assume the underlying
file has not changed size, as was true on the box (Linux) the person
who changed this test in 2.2 to begin with tried it on).  Without this
change, test_mmap fails on Windows.  Now it passes again.

23 years agounicode_memchr(): Squashed compiler wng (signed-vs-unsigned comparison).
Tim Peters [Tue, 24 Sep 2002 15:22:30 +0000 (15:22 +0000)] 
unicode_memchr():  Squashed compiler wng (signed-vs-unsigned comparison).

23 years agoRegenerate test_unicodedata output after the change to the UTF-8 codec.
Marc-André Lemburg [Tue, 24 Sep 2002 15:01:01 +0000 (15:01 +0000)] 
Regenerate test_unicodedata output after the change to the UTF-8 codec.

23 years agoBackport the UTF-8 codec from 2.3 and add a work-around to let the
Marc-André Lemburg [Tue, 24 Sep 2002 14:06:55 +0000 (14:06 +0000)] 
Backport the UTF-8 codec from 2.3 and add a work-around to let the
UTF-8 decoder accept broken UTF-8 sequences which encode lone
high surrogates (the pre-2.2.2 versions forgot to generate the
UTF-8 prefix \xed for these).

Fixes SF bug #610783: Lone surrogates cause bad .pyc files.

23 years agoClarify that len() of a Unicode string returns the number of storage units,
Fred Drake [Tue, 24 Sep 2002 13:57:32 +0000 (13:57 +0000)] 
Clarify that len() of a Unicode string returns the number of storage units,
not abstract characters.

23 years agobackport theller's checkin of
Michael W. Hudson [Tue, 24 Sep 2002 11:56:45 +0000 (11:56 +0000)] 
backport theller's checkin of
    revision 1.74 of marshal.c

Whitespace normalization.

23 years agobackport theller's checkin of
Michael W. Hudson [Tue, 24 Sep 2002 11:56:15 +0000 (11:56 +0000)] 
backport theller's checkin of
    revision 1.3 of test_marshal.py

Fix SF 588452: debug build crashes on marshal.dumps([128] * 1000).
See there for a description.

Added test case.

Bugfix candidate for 2.2.x, not sure about previous versions:
probably low priority, because virtually no one runs debug builds.

23 years agobackport theller's checkin of
Michael W. Hudson [Tue, 24 Sep 2002 11:55:54 +0000 (11:55 +0000)] 
backport theller's checkin of
    revision 1.73 of marshal.c

Fix SF 588452: debug build crashes on marshal.dumps([128] * 1000).
See there for a description.

Added test case.

Bugfix candidate for 2.2.x, not sure about previous versions:
probably low priority, because virtually no one runs debug builds.

23 years agobackport jhylton's checkin of
Michael W. Hudson [Tue, 24 Sep 2002 11:53:34 +0000 (11:53 +0000)] 
backport jhylton's checkin of
    revision 2.87 of cPickle.c

Do more robust test of whether global objects are accessible.

PyImport_ImportModule() is not guaranteed to return a module object.
When another type of object was returned, the PyModule_GetDict() call
return NULL and the subsequent GetItem() seg faulted.

Bug fix candidate.

----------

Once again, whitespace chances scuppered automatic backporting, so
I did this by hand.  Review probably wise -- but I have run make test!

Also incorporates revision 2.88 which was just removing a now unused
declaration.

23 years agobackport nowonder's checkin of
Michael W. Hudson [Tue, 24 Sep 2002 11:23:05 +0000 (11:23 +0000)] 
backport nowonder's checkin of
    revision 2.265 of bltinmodule.c

date: 2002/08/27 16:58:00;  author: nowonder;  state: Exp;  lines: +1 -1

execfile should call PyErr_SetFromErrnoWithFilename instead of
simply PyErr_SetFromErrno

This closes bug 599163.

23 years agobackport akuchling's checkin of
Michael W. Hudson [Tue, 24 Sep 2002 11:22:28 +0000 (11:22 +0000)] 
backport akuchling's checkin of
    revision 1.12 of config.py

Include an empty body when checking for a header file

(Bugfix candidate for 2.2, and likely 2.1 as well)

23 years agobackport gvanrossum's checkin of
Michael W. Hudson [Tue, 24 Sep 2002 11:19:33 +0000 (11:19 +0000)] 
backport gvanrossum's checkin of
    revision 1.57 of pdb.py

date: 2002/09/10 21:57:14;  author: gvanrossum;  state: Exp;  lines: +7 -1
At Jim Fulton's request, increase the maxstring value of _saferepr to
a more reasonable value.

Backport candidate.

23 years agobackport effbot's checkin of
Michael W. Hudson [Tue, 24 Sep 2002 11:12:05 +0000 (11:12 +0000)] 
backport effbot's checkin of
    revision 1.43 of sre_compile.py

made the code match the comments (1.5.2 compatibility)

23 years agobackport theller's checkin of
Michael W. Hudson [Tue, 24 Sep 2002 11:11:12 +0000 (11:11 +0000)] 
backport theller's checkin of
    revision 2.102 of abstract.c

Better isinstance error message.

Closes SF patch # 560250.

Bugfix candidate IMO.

23 years agobackport bwarsaw's checkin of
Michael W. Hudson [Tue, 24 Sep 2002 11:08:23 +0000 (11:08 +0000)] 
backport bwarsaw's checkin of
    revision 2.101 of abstract.c

abstract_get_bases(): Clarify exactly what the return values and
states can be for this function, and ensure that only AttributeErrors
are masked.  Any other exception raised via the equivalent of
getattr(cls, '__bases__') should be propagated up.

abstract_issubclass(): If abstract_get_bases() returns NULL, we must
call PyErr_Occurred() to see if an exception is being propagated, and
return -1 or 0 as appropriate.  This is the specific fix for a problem
whereby if getattr(derived, '__bases__') raised an exception, an
"undetected error" would occur (under a debug build).  This nasty
situation was uncovered when writing a security proxy extension type
for the Zope3 project, where the security proxy raised a Forbidden
exception on getattr of __bases__.

PyObject_IsInstance(), PyObject_IsSubclass(): After both calls to
abstract_get_bases(), where we're setting the TypeError if the return
value is NULL, we must first check to see if an exception occurred,
and /not/ mask an existing exception.

Neil Schemenauer should double check that these changes don't break
his ExtensionClass examples (there aren't any test cases for those
examples and abstract_get_bases() was added by him in response to
problems with ExtensionClass).  Neil, please add test cases if
possible!

I belive this is a bug fix candidate for Python 2.2.2.

----

Whitespace normalization made this a pest to backport...

Did a test case ever get added for this?

23 years agoFinish up the random fixes that Raymond started yesterday.
Michael W. Hudson [Tue, 24 Sep 2002 10:27:28 +0000 (10:27 +0000)] 
Finish up the random fixes that Raymond started yesterday.

23 years agoMake test_rfc822 pass again.
Michael W. Hudson [Tue, 24 Sep 2002 09:59:50 +0000 (09:59 +0000)] 
Make test_rfc822 pass again.

23 years agoFix cast from backport.
Marc-André Lemburg [Tue, 24 Sep 2002 09:29:44 +0000 (09:29 +0000)] 
Fix cast from backport.

23 years agoBackport 2.48 from trunk:
Guido van Rossum [Tue, 24 Sep 2002 01:17:41 +0000 (01:17 +0000)] 
Backport 2.48 from trunk:

#544265, Remove warnings for passing const to free()

23 years agoBackported 1.39 and 1.40 from trunk:
Guido van Rossum [Mon, 23 Sep 2002 21:19:44 +0000 (21:19 +0000)] 
Backported 1.39 and 1.40 from trunk:

1.39:
Fix SF bug 610610 (reported by Martijn Pieters, diagnosed by Neal Norwitz).

The switch in Exception__str__ didn't clear the error if
PySequence_Size() raised an exception.  Added a case -1 which clears
the error and falls through to the default case.

1.40:
Two more cases of switch(PySequence_Size()) without checking for case -1.
(Same problem as last checkin for SF bug 610610)
Need to clear the error and proceed.

23 years agoBackport from trunk:
Guido van Rossum [Mon, 23 Sep 2002 21:17:27 +0000 (21:17 +0000)] 
Backport from trunk:

unicodeobject.c 2.169
stringobject.c 2.189

Fix warnings on 64-bit platforms about casts from pointers to ints.
Two of these were real bugs.

23 years agoAdd the snake-farm crew.
Guido van Rossum [Mon, 23 Sep 2002 21:04:09 +0000 (21:04 +0000)] 
Add the snake-farm crew.

23 years agoBackport 2.93 from trunk:
Guido van Rossum [Mon, 23 Sep 2002 21:02:33 +0000 (21:02 +0000)] 
Backport 2.93 from trunk:

Insert an overflow check when the sequence repetition count is outside
the range of ints.  The old code would pass random truncated bits to
sq_repeat() on a 64-bit machine.

23 years agoBackport 1.51 and 1.54 from trunk.
Guido van Rossum [Mon, 23 Sep 2002 20:59:28 +0000 (20:59 +0000)] 
Backport 1.51 and 1.54 from trunk.

1.51:
Bug #556025: list(xrange(1e9)) --> seg fault

Close the bug report again -- this time for Cygwin due to a newlib bug.
See the following for the details:

http://sources.redhat.com/ml/newlib/2002/msg00369.html

Note that this commit is only a documentation (i.e., comment) change.

1.54:
The list(xrange(sys.maxint / 4)) test blew up on 64-bit platforms.
Because ob_size is a 32-bit int but sys.maxint is LONG_MAX which is a
64-bit value, there's no way to make this test succeed on a 64-bit
platform.  So just skip it when sys.maxint isn't 0x7fffffff.

23 years agoBackport 2.57 from trunk:
Guido van Rossum [Mon, 23 Sep 2002 20:54:04 +0000 (20:54 +0000)] 
Backport 2.57 from trunk:

(Most of) SF patch 601369 (Christos Georgiou): obmalloc,structmodule:
64bit, big endian (issue 2 only).

This adds a bunch of memcpy calls via a temporary variable to avoid
alignment errors.  That's needed for some platforms.

23 years agoBackport 1.56 and 1.68 from trunk:
Guido van Rossum [Mon, 23 Sep 2002 20:49:43 +0000 (20:49 +0000)] 
Backport 1.56 and 1.68 from trunk:

1.56:
Apply diff3.txt from SF patch http://www.python.org/sf/536241

If a str or unicode method returns the original object,
make sure that for str and unicode subclasses the original
will not be returned.

This should prevent SF bug http://www.python.org/sf/460020
from reappearing.

1.68:
Fix SF bug 599128, submitted by Inyeol Lee: .replace() would do the
wrong thing for a unicode subclass when there were zero string
replacements.  The example given in the SF bug report was only one way
to trigger this; replacing a string of length >= 2 that's not found is
another.  The code would actually write outside allocated memory if
replacement string was longer than the search string.

23 years agoBackport 2.166 from trunk:
Guido van Rossum [Mon, 23 Sep 2002 20:46:52 +0000 (20:46 +0000)] 
Backport 2.166 from trunk:

Fix SF bug 599128, submitted by Inyeol Lee: .replace() would do the
wrong thing for a unicode subclass when there were zero string
replacements.  The example given in the SF bug report was only one way
to trigger this; replacing a string of length >= 2 that's not found is
another.  The code would actually write outside allocated memory if
replacement string was longer than the search string.

23 years agoBackport 1.96 from trunk (because I want Xenofarm to test 2.2.2):
Guido van Rossum [Mon, 23 Sep 2002 20:45:36 +0000 (20:45 +0000)] 
Backport 1.96 from trunk (because I want Xenofarm to test 2.2.2):

Add a bunch of sys.stdout.flush() calls that will hopefully improve
the usability of the output of the Xenofarm builds.

23 years agoBackport:
Raymond Hettinger [Mon, 23 Sep 2002 14:52:40 +0000 (14:52 +0000)] 
Backport:

SF bug 594996:  OverflowError in random.randrange
Loosened the acceptable 'start' and 'stop' arguments so that any
Python (bounded) ints can be used.  So, e.g., randrange(-sys.maxint-1,
sys.maxint) no longer blows up.

23 years agoWhitespace normalization and backport:
Raymond Hettinger [Mon, 23 Sep 2002 14:48:16 +0000 (14:48 +0000)] 
Whitespace normalization and backport:

random.gauss() uses a piece of hidden state used by nothing else,
and the .seed() and .whseed() methods failed to reset it.  In other
words, setting the seed didn't completely determine the sequence of
results produced by random.gauss().  It does now.  Programs repeatedly
mixing calls to a seed method with calls to gauss() may see different
results now.

Bugfix candidate (random.gauss() has always been broken in this way),
despite that it may change results.

23 years agoBackport:
Raymond Hettinger [Mon, 23 Sep 2002 14:37:00 +0000 (14:37 +0000)] 
Backport:

The test for re.engine was misfiring because re.engine is no longer
defined and the default was "pre" instead of "sre".  Give up on 1.5.2
compatibility, hardcode the sre solution.  However, this XXX comment
still applies, AFAIK:
        # XXX This code depends on internals of the regular expression
        # engine!  There's no standard API to do a substitution when you
        # have already found the match.  One should be added.

23 years agoBackport:
Raymond Hettinger [Mon, 23 Sep 2002 14:30:24 +0000 (14:30 +0000)] 
Backport:

Convert characters from the locale's encoding on output.
Reject characters outside the locale's encoding on input.

23 years agoBackport patch: Use ascii_letters to avoid UnicodeErrors.
Raymond Hettinger [Mon, 23 Sep 2002 14:23:15 +0000 (14:23 +0000)] 
Backport patch:  Use ascii_letters to avoid UnicodeErrors.

23 years agoBackport patch #540583: Open MS Help Docs if available.
Raymond Hettinger [Mon, 23 Sep 2002 14:17:15 +0000 (14:17 +0000)] 
Backport patch #540583: Open MS Help Docs if available.

23 years agoBackport:
Raymond Hettinger [Mon, 23 Sep 2002 14:06:24 +0000 (14:06 +0000)] 
Backport:

Properly fix SF bug #507298 (Gregor Lingl): shellpython2.2 -Qnew smart
indent error

Use // where int division is intended.

23 years agoWarn about binutils 2.13 on Solaris.
Guido van Rossum [Mon, 23 Sep 2002 14:02:44 +0000 (14:02 +0000)] 
Warn about binutils 2.13 on Solaris.

23 years agoBackport patch 543222. Disable script bindings in shell window.
Raymond Hettinger [Mon, 23 Sep 2002 14:01:40 +0000 (14:01 +0000)] 
Backport patch 543222. Disable script bindings in shell window.

23 years agoBackport patches 558535. The standard Windows binding for Edit Select All
Raymond Hettinger [Mon, 23 Sep 2002 13:44:45 +0000 (13:44 +0000)] 
Backport patches 558535.  The standard Windows binding for Edit Select All
is Control-A rather than Alt-A.

23 years agobackport bwarsaw's checkin of
Michael W. Hudson [Mon, 23 Sep 2002 13:40:29 +0000 (13:40 +0000)] 
backport bwarsaw's checkin of
    revision 1.70 of rfc822.py

parseaddr(): Fixed in the same way that Message.getaddrlist() was
fixed (re: SF bug #555035).  Include a unittest.

23 years agobackport bwarsaw's checkin of
Michael W. Hudson [Mon, 23 Sep 2002 13:32:53 +0000 (13:32 +0000)] 
backport bwarsaw's checkin of
    revision 1.17 of test_rfc822.py

parseaddr(): Fixed in the same way that Message.getaddrlist() was
fixed (re: SF bug #555035).  Include a unittest.

23 years agoUpdate canvas before computing width. Draw turtle when done drawing circle.
Martin v. Löwis [Sun, 22 Sep 2002 13:02:10 +0000 (13:02 +0000)] 
Update canvas before computing width. Draw turtle when done drawing circle.
Fixes #612595.

23 years agoBack out multifile.py 1.19 and 1.20. Fixes #514676.
Martin v. Löwis [Sun, 22 Sep 2002 09:03:03 +0000 (09:03 +0000)] 
Back out multifile.py 1.19 and 1.20. Fixes #514676.

23 years agoThis commit was manufactured by cvs2svn to create branch
cvs2svn [Sun, 22 Sep 2002 09:03:03 +0000 (09:03 +0000)] 
This commit was manufactured by cvs2svn to create branch
'release22-maint'.

23 years agoAdd recursion limit to pickling. Fixes #576084.
Martin v. Löwis [Sun, 22 Sep 2002 08:21:45 +0000 (08:21 +0000)] 
Add recursion limit to pickling. Fixes #576084.

23 years agoBackport (the relevant part of) rexec.py 1.41.
Guido van Rossum [Sun, 15 Sep 2002 06:08:27 +0000 (06:08 +0000)] 
Backport (the relevant part of) rexec.py 1.41.

Address SF bug #577530: del __builtins__ breaks out of rexec

Using the suggestion there: add_module() forces __builtin__ back; this
fixes r_exec, r_eval, r_execfile.

This does not mean that rexec is now considered safe!  But for those
willing to take the risk, it's safer than before.  (Note that a safety
analysis of the code module would be wise if you plan to use the
interactive console for real -- I've only ever used it to play with
restricted mode.)

23 years agoSF # 602108 ensure string is null terminated after strncpy
Neal Norwitz [Fri, 13 Sep 2002 14:40:50 +0000 (14:40 +0000)] 
SF # 602108 ensure string is null terminated after strncpy

23 years agoFix typo reported by Paul Clifford.
Fred Drake [Thu, 12 Sep 2002 14:16:31 +0000 (14:16 +0000)] 
Fix typo reported by Paul Clifford.
Note that there is no str.joinfields(), use str.join() instead.

23 years agoRevise text about the level of DOM support, and provide pointers to
Fred Drake [Wed, 11 Sep 2002 22:04:51 +0000 (22:04 +0000)] 
Revise text about the level of DOM support, and provide pointers to
the work of the XML-SIG in the main body of the text.  Incorporates
changes made by Martin von Löwis in revision 1.20 on the trunk.

Modify the markup in a few places to avoid wrapping lines in bad
places, and just general cleanliness.

23 years agoAdd windows-125[678]. Fixes #607302.
Martin v. Löwis [Wed, 11 Sep 2002 16:29:52 +0000 (16:29 +0000)] 
Add windows-125[678]. Fixes #607302.

23 years agoClarify who maintains Tkinter and who maintains Tk.
Fred Drake [Tue, 10 Sep 2002 21:59:44 +0000 (21:59 +0000)] 
Clarify who maintains Tkinter and who maintains Tk.

23 years agoUse = instead of == in test.
Martin v. Löwis [Tue, 10 Sep 2002 09:19:45 +0000 (09:19 +0000)] 
Use = instead of == in test.

23 years agoFix API typo. Closes SF 606216
Raymond Hettinger [Sun, 8 Sep 2002 04:42:16 +0000 (04:42 +0000)] 
Fix API typo.  Closes SF 606216

23 years agoTry to get test to pass on Windows
Neal Norwitz [Sat, 7 Sep 2002 05:58:28 +0000 (05:58 +0000)] 
Try to get test to pass on Windows

23 years agoChange UserDict to IterableUserDict
Raymond Hettinger [Sat, 7 Sep 2002 04:49:09 +0000 (04:49 +0000)] 
Change UserDict to IterableUserDict

23 years agoHave os.environ inherit from the iterable version of UserDict.
Raymond Hettinger [Fri, 6 Sep 2002 19:35:22 +0000 (19:35 +0000)] 
Have os.environ inherit from the iterable version of UserDict.
Closes SF bug 605731.

23 years agoAdded a tutorial note and example regarding the scope of loop variables
Raymond Hettinger [Fri, 6 Sep 2002 18:09:22 +0000 (18:09 +0000)] 
Added a tutorial note and example regarding the scope of loop variables
in a list comprehension.  Includes a justification and a comparision
to regular for-loops.

Closes SF bug 605047.

23 years agoBackport of SF bug # 585792, Invalid mmap crashes Python interpreter
Neal Norwitz [Thu, 5 Sep 2002 22:30:03 +0000 (22:30 +0000)] 
Backport of SF bug # 585792, Invalid mmap crashes Python interpreter

Raise ValueError if user passes a size to mmap which is larger
than the file.

Also need Tim's fix in test_mmap.py, 1.22 which flushes the file
before mmap'ing it.

23 years agoFix typo
Raymond Hettinger [Wed, 4 Sep 2002 15:12:55 +0000 (15:12 +0000)] 
Fix typo

23 years agoFix typo
Raymond Hettinger [Wed, 4 Sep 2002 15:02:53 +0000 (15:02 +0000)] 
Fix typo

23 years agoBackport:
Guido van Rossum [Tue, 3 Sep 2002 16:36:59 +0000 (16:36 +0000)] 
Backport:

Fix for SF bug 601077 by Zack Weinberg.

The new execvpe code would sometimes do the wrong thing when a
non-executable file existed earlier in the path and an executable file
of the same name existed later in the path.  This patch restores the
proper behavior (which is to execute the second file).  When only a
non-executable file exists, the correct error is still reported.

23 years agoBackported Skip's update to revision 1.34
Raymond Hettinger [Wed, 28 Aug 2002 02:10:04 +0000 (02:10 +0000)] 
Backported Skip's update to revision 1.34

23 years agoNote change in behavior from 1.5.2. The new argument to NameError is
Raymond Hettinger [Tue, 27 Aug 2002 23:54:57 +0000 (23:54 +0000)] 
Note change in behavior from 1.5.2.  The new argument to NameError is
an error message and not just the missing name.

Closes SF Bug 599869.

23 years agoAdd strong security warning about the rexec module.
Fred Drake [Tue, 27 Aug 2002 16:44:18 +0000 (16:44 +0000)] 
Add strong security warning about the rexec module.
Closes SF patch #600861.

Minor markup changes.

23 years agoCorrect documentation of allow_reuse_address to match the actual script.
Raymond Hettinger [Sun, 25 Aug 2002 16:31:27 +0000 (16:31 +0000)] 
Correct documentation of allow_reuse_address to match the actual script.

Closes SF bug 599681.

23 years agoFix typo reported to python-docs.
Fred Drake [Fri, 23 Aug 2002 21:20:11 +0000 (21:20 +0000)] 
Fix typo reported to python-docs.

23 years agobackport effbot's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:34:08 +0000 (16:34 +0000)] 
backport effbot's checkin of
    revision 1.13 of pre.py

Fix bug #570057: Broken pre.subn() (and pre.sub())

This should be backported to the 2.2.X series (how
do I do that?)

23 years agobackport gvanrossum's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:30:07 +0000 (16:30 +0000)] 
backport gvanrossum's checkin of
    revision 1.180 of ACKS

date: 2002/06/10 20:00:52;  author: gvanrossum;  state: Exp;  lines: +1 -0
SF patch 564549 (Erik Andersén).

The WeakKeyDictionary constructor didn't work when a dict arg was
given.  Fixed by moving a line.  Also adding a unit test.

Bugfix candidate.

23 years agobackport gvanrossum's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:29:27 +0000 (16:29 +0000)] 
backport gvanrossum's checkin of
    revision 1.19 of test_weakref.py

SF patch 564549 (Erik Andersén).

The WeakKeyDictionary constructor didn't work when a dict arg was
given.  Fixed by moving a line.  Also adding a unit test.

Bugfix candidate.

23 years agobackport gvanrossum's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:29:01 +0000 (16:29 +0000)] 
backport gvanrossum's checkin of
    revision 1.17 of weakref.py

SF patch 564549 (Erik Andersén).

The WeakKeyDictionary constructor didn't work when a dict arg was
given.  Fixed by moving a line.  Also adding a unit test.

Bugfix candidate.

23 years agobackport gvanrossum's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:28:16 +0000 (16:28 +0000)] 
backport gvanrossum's checkin of
    revision 1.86 of libos.tex

SF bug 563750 (Alex Martelli): posix_tmpfile():

The file returned by tmpfile() has mode w+b, so use that in the call
to PyFile_FromFile().

Bugfix candidate.

23 years agobackport gvanrossum's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:27:40 +0000 (16:27 +0000)] 
backport gvanrossum's checkin of
    revision 2.234 of posixmodule.c

SF bug 563750 (Alex Martelli): posix_tmpfile():

The file returned by tmpfile() has mode w+b, so use that in the call
to PyFile_FromFile().

Bugfix candidate.

23 years agobackport loewis' checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:26:17 +0000 (16:26 +0000)] 
backport loewis' checkin of
    revision 1.309 of configure
    revision 1.319 of configure.in

Use somewhat longer C++ program to detect whether linking requires the C++
compiler. Fixes #559429. 2.2 bugfix candidate.

23 years agobackport montanaro's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:10:13 +0000 (16:10 +0000)] 
backport montanaro's checkin of
    revision 1.9 of test_gzip.py

force gzip module to open files using 'b'inary mode.
closes patch #536278.

23 years agobackport montanaro's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:09:52 +0000 (16:09 +0000)] 
backport montanaro's checkin of
    revision 1.33 of gzip.py

force gzip module to open files using 'b'inary mode.
closes patch #536278.

This looked like a bugfix candidate to me at some point...

23 years agobackport bwarsaw's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:08:38 +0000 (16:08 +0000)] 
backport bwarsaw's checkin of
    revision 1.6 of emailutil.tex

Minor typo: Message.getall() -> Message.get_all()

23 years agobackport gvanrossum's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:06:46 +0000 (16:06 +0000)] 
backport gvanrossum's checkin of
    revision 1.22 of test_fcntl.py

SF 554663.  Add OpenBSD3.  Bugfix candidate if anyone cares.

23 years agobackport loewis' checkin of
Michael W. Hudson [Fri, 23 Aug 2002 16:05:49 +0000 (16:05 +0000)] 
backport loewis' checkin of
    revision 1.83 of Makefile.pre.in

Patch #553230: Create LIBDIR if necessary. Bugfix candidate.

23 years agobackport tim_one's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 15:53:05 +0000 (15:53 +0000)] 
backport tim_one's checkin of
    revision 1.4 of CallTipWindow.py

SF bug 546078:  IDLE calltips cause application error.
Assorted crashes on Windows and Linux when trying to display a very
long calltip, most likely a Tk bug.  Wormed around by clamping the
calltip display to a maximum of 79 characters (why 79? why not ...).

Bugfix candidate, for all Python releases.

23 years agobackport tim_one's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 15:50:57 +0000 (15:50 +0000)] 
backport tim_one's checkin of
    revision 1.21 of test_mmap.py

SF bug 544733:  Cygwin test_mmap fix for Python 2.2.1
Close a file before trying to unlink it, and apparently Cygwin needs
writes to an mmap'ed file to get flushed before they're visible.

Bugfix candidate, but I think only for the 2.2 line (it's testing
features that I think were new in 2.2).

23 years agobackport gvanrossum's checkin of
Michael W. Hudson [Fri, 23 Aug 2002 15:42:27 +0000 (15:42 +0000)] 
backport gvanrossum's checkin of
    revision 1.52 of pdb.py

date: 2002/04/15 00:48:24;  author: gvanrossum;  state: Exp;  lines: +4 -1
Add exit as alias for quit, as the easiest way to address SF bug
#543674.

Bugfix candidate.

23 years agobackport loewis' checkin of
Michael W. Hudson [Fri, 23 Aug 2002 15:27:52 +0000 (15:27 +0000)] 
backport loewis' checkin of
    revision 1.161 of Tkinter.py

Ignore widgets with unknown names in winfo_children. Fixes #518283.
2.2.2 candidate.

23 years agoAdd a note that apply() is needed since the extended call syntax is
Fred Drake [Thu, 22 Aug 2002 14:27:22 +0000 (14:27 +0000)] 
Add a note that apply() is needed since the extended call syntax is
completely equivalent.

23 years agoClarify that even though some of the relevant specifications define the
Fred Drake [Wed, 21 Aug 2002 19:24:43 +0000 (19:24 +0000)] 
Clarify that even though some of the relevant specifications define the
order in which form variables should be encoded in a request, a CGI script
should not rely on that since a client may not conform to those specs, or
they may not be relevant to the request.
Closes SF bug #596866.

23 years agoSF 595846. Backport deltas from 1.26 to 1.28.
Raymond Hettinger [Tue, 20 Aug 2002 23:59:33 +0000 (23:59 +0000)] 
SF 595846.  Backport deltas from 1.26 to 1.28.

23 years agoFix some endcase bugs in unicode rfind()/rindex() and endswith().
Guido van Rossum [Tue, 20 Aug 2002 16:57:58 +0000 (16:57 +0000)] 
Fix some endcase bugs in unicode rfind()/rindex() and endswith().
These were reported and fixed by Inyeol Lee in SF bug 595350.  The
endswith() bug is already fixed in 2.3; I'll fix the others in
2.3 next.

23 years agoClarify the endpos argument to the rx.match() method.
Fred Drake [Tue, 20 Aug 2002 13:58:12 +0000 (13:58 +0000)] 
Clarify the endpos argument to the rx.match() method.
Closes SF bug #597177.

23 years agoExtend some comments on the order of values in the returns from
Fred Drake [Mon, 19 Aug 2002 22:01:19 +0000 (22:01 +0000)] 
Extend some comments on the order of values in the returns from
dict.items/keys/values/iteritems/iterkeys/itervalues().

23 years agoA trip down memory lane. Barry checked in this test with 2.3-style
Tim Peters [Mon, 19 Aug 2002 01:20:09 +0000 (01:20 +0000)] 
A trip down memory lane.  Barry checked in this test with 2.3-style
imports of test_support.  That causes multiple copies of test_support
to get loaded, and the one used by test_base64.py didn't see the proper
value of verbose=False, so spewed output.  That in turn apparenly caused
Barry to check in an expected-results output file, but a unitttest-based
test should never have one of those.  I noticed this because, on Windows,
the final unittest output line contains the number of seconds needed to
run the test, and that varied on *some* runs when I tried it, causing
bogus test failures.

Anyway, this gets rid of the expected-output file again, and changes
the imports to work with 2.2's way of doing this.

23 years agoSF bug 595919: popenN return only text mode pipes
Tim Peters [Mon, 19 Aug 2002 00:43:06 +0000 (00:43 +0000)] 
SF bug 595919: popenN return only text mode pipes
popen2() and popen3() created text-mode pipes even when binary mode
was asked for.  This was specific to Windows.

23 years agoModify splituser() method to allow an @ in the userinfo field.
Raymond Hettinger [Sun, 18 Aug 2002 20:10:08 +0000 (20:10 +0000)] 
Modify splituser() method to allow an @ in the userinfo field.
Jeremy reported that this is not allowed by RFC 2396; however,
other tools support unescaped @'s so we should also.

Apply SF patch 596581 closing bug 581529.

23 years agoBackport of fix for SF bug #595671 from Python 2.3cvs:
Barry Warsaw [Thu, 15 Aug 2002 22:18:11 +0000 (22:18 +0000)] 
Backport of fix for SF bug #595671 from Python 2.3cvs:

    base64.decodestring('') should return '' instead of raising an
    exception.  The bug fix for SF #430849 wasn't quite right.  This
    closes SF bug #595671.  I'll backport this to Python 2.2.

One addition here is that there was no test of the base64 module in
Python 2.2 cvs yet, so I added that too.

23 years agoThis commit was manufactured by cvs2svn to create branch
cvs2svn [Thu, 15 Aug 2002 22:18:11 +0000 (22:18 +0000)] 
This commit was manufactured by cvs2svn to create branch
'release22-maint'.

23 years agoBackport:
Guido van Rossum [Wed, 14 Aug 2002 17:36:26 +0000 (17:36 +0000)] 
Backport:
PyType_Ready(): initialize the base class a bit earlier, so that if we
copy the metatype from the base, the base actually has one!

23 years agoRemove a broken example of extreme backward compatibility; it is
Fred Drake [Wed, 14 Aug 2002 15:27:19 +0000 (15:27 +0000)] 
Remove a broken example of extreme backward compatibility; it is
simply not relevant any more.
Closes SF bug #595032.

23 years agoSF bug #574235, convert_path fails with empty pathname
Neal Norwitz [Tue, 13 Aug 2002 17:49:18 +0000 (17:49 +0000)] 
SF bug #574235, convert_path fails with empty pathname