Facundo Batista [Thu, 14 Aug 2008 16:51:00 +0000 (16:51 +0000)]
Issue 1432. Fixes a bug caused because of the evolution
of the RFC that describes the behaviour. Note that we now
have the same behaviour than the current browsers.
Brett Cannon [Thu, 14 Aug 2008 05:55:18 +0000 (05:55 +0000)]
Fix markup for various binary operation examples where the operands were bolded
and the operator was made literal, leading to non-valid reST. Changed to have
the entire expression just be a literal bit of text.
Brett Cannon [Thu, 14 Aug 2008 05:00:03 +0000 (05:00 +0000)]
Silence the DeprecationWarning of rfc822 triggered by its importation in
mimetools.
This has an unfortunate side-effect of potentially not letting any warning
about rfc822's deprecation be seen by user-visible code if rfc822 is not
imported before mimetools. This is because modules are cached in sys.modules
and thus do not have their deprecation triggered more than once. But this
silencing would have happened by other code that silences the use of mimetools
or rfc822 anyway in the stdlib or user code, and thus seems justified to be
done here.
- PC/VC6/_bsddb.dsp:
removed '/nodefaultlib:"msvcrt"' to fix linker error.
- PC/VC6/_msi.dsp, PC/VC6/pcbuild.dsw:
added new module support.
- PC/VC6/_sqlite3.dsp:
/D "MODULE_NAME=\"sqlite3\""
caused extra leading space like
#define MODULE_NAME " sqlite3"
so uses
/D MODULE_NAME=\"sqlite3\"
instead.
- PC/VC6/python.dsp:
changed stack size to 2MB to avoid stack overflow on
some tests.
Martin v. Löwis [Tue, 12 Aug 2008 14:49:50 +0000 (14:49 +0000)]
Issue #3139: Make buffer-interface thread-safe wrt. PyArg_ParseTuple,
by denying s# to parse objects that have a releasebuffer procedure,
and introducing s*.
More module might need to get converted to use s*.
Nick Coghlan [Mon, 11 Aug 2008 15:45:58 +0000 (15:45 +0000)]
Issue 2235: Py3k warnings are now emitted for classes that will no longer inherit a__hash__ implementation from a parent class in Python 3.x. The standard library and test suite have been updated to not emit these warnings.
Brett Cannon [Sat, 9 Aug 2008 23:06:16 +0000 (23:06 +0000)]
Suppress the warning in asynchat from using buffer() when running udner -3.
Naively removing the usage causes a large number of test failures, so it was
just easier to suppress the warning.
Brett Cannon [Fri, 8 Aug 2008 04:27:28 +0000 (04:27 +0000)]
Remove buffer() usage in the socket module by just slicing directly on the
object. This removes all warnings for the module caused by running under -3.
Brett Cannon [Fri, 8 Aug 2008 04:19:32 +0000 (04:19 +0000)]
Remove warnings generated for the suprocess module when run under -3. Required
commenting out True/False compatbility stuff, remove a use of apply(), and
remove a use of buffer() (just pulled the solution used in 3.0 which is direct
slicing).
This is a verifier for the binary code used by the _sre module (this
is often called bytecode, though to distinguish it from Python bytecode
I put it in quotes).
I wrote this for Google App Engine, and am making the patch available as
open source under the Apache 2 license. Below are the copyright
statement and license, for completeness.
# Copyright 2008 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
It's not necessary to include these copyrights and bytecode in the
source file. Google has signed a contributor's agreement with the PSF
already.
#3367 from Kristjan Valur Jonsson:
If a PyTokenizer_FromString() is called with an empty string, the
tokenizer's line_start member never gets initialized. Later, it is
compared with the token pointer 'a' in parsetok.c:193 and that behavior
can result in undefined behavior.
Brett Cannon [Mon, 4 Aug 2008 21:52:25 +0000 (21:52 +0000)]
Add a note about all the modules/packages changed to silence -3 warnings. More
changes are needed once some decisions are made, but this is the work up to this
point.
Mark Dickinson [Mon, 4 Aug 2008 21:30:09 +0000 (21:30 +0000)]
Issue #1481296: (again!) Make conversion of a float NaN to an int or
long raise ValueError instead of returning 0. Also, change the error
message for conversion of an infinity to an integer, replacing 'long' by
'integer', so that it's appropriate for both long(float('inf')) and
int(float('inf')).
Nick Coghlan [Mon, 4 Aug 2008 12:40:59 +0000 (12:40 +0000)]
Issue 643841: better documentation of the special method lookup process, especially for new-style classes. Also removes the warnings about not being authoritative for new-style classes - the language reference actually covers those fairly well now (albeit in a fashion that isn't always particularly easy to follow).
Adds a sanity check to avoid a *very rare* infinite loop due to a corrupt tls
key list data structure in the thread startup path.
This change is a companion to r60148 which already successfully dealt with a
similar issue on thread shutdown.
In particular this loop has been observed happening from this call path:
#0 in find_key ()
#1 in PyThread_set_key_value ()
#2 in _PyGILState_NoteThreadState ()
#3 in PyThreadState_New ()
#4 in t_bootstrap ()
#5 in pthread_start_thread ()
I don't know how this happens but it does, *very* rarely. On more than
one hardware platform. I have not been able to reproduce it manually.
(A flaky mutex implementation on the system in question is one hypothesis).
As with r60148, the spinning we managed to observe in the wild was due to a
single list element pointing back upon itself.
- Issue #1857: subprocess.Popen.poll gained an additional _deadstate keyword
argument in python 2.5, this broke code that subclassed Popen to include its
own poll method. Fixed my moving _deadstate to an _internal_poll method.
Lars Gustäbel [Sat, 2 Aug 2008 11:26:39 +0000 (11:26 +0000)]
Issue #3039: Fix TarFileCompat.writestr() which always raised an
AttributeError since __slots__ were added to zipfile.ZipInfo in
r46967 two years ago.
Add a warning about the removal of TarFileCompat in Python 3.0.