Brett Cannon [Thu, 23 Feb 2012 23:29:12 +0000 (18:29 -0500)]
Improper type for __package__ should raise TypeError, not ValueError.
Brett Cannon [Thu, 23 Feb 2012 23:18:48 +0000 (18:18 -0500)]
Do a type check instead of an interface check.
Brett Cannon [Thu, 23 Feb 2012 15:17:56 +0000 (10:17 -0500)]
Merge
Nadeem Vawda [Thu, 23 Feb 2012 12:23:17 +0000 (14:23 +0200)]
Simplify zlib bigmem tests.
Nadeem Vawda [Thu, 23 Feb 2012 12:16:15 +0000 (14:16 +0200)]
Fix previous fix (for test_zlib) to work on 32-bit systems.
Nadeem Vawda [Thu, 23 Feb 2012 11:36:25 +0000 (13:36 +0200)]
Issue #13873: Fix crash in test_zlib on bigmem buildbot.
Brett Cannon [Wed, 22 Feb 2012 23:33:05 +0000 (18:33 -0500)]
Refactor importlib to make it easier to re-implement in C.
Victor Stinner [Wed, 22 Feb 2012 20:22:20 +0000 (21:22 +0100)]
Fix doc of an internal function: unicode_write_cstr()
Charles-François Natali [Wed, 22 Feb 2012 20:03:09 +0000 (21:03 +0100)]
Issue #14077: importlib: Fix regression introduced by
de6703671386.
Antoine Pitrou [Wed, 22 Feb 2012 18:23:13 +0000 (19:23 +0100)]
Null merge
Antoine Pitrou [Wed, 22 Feb 2012 17:08:30 +0000 (18:08 +0100)]
Issue #14084: Fix a file descriptor leak when importing a module with a bad encoding.
Antoine Pitrou [Wed, 22 Feb 2012 17:05:43 +0000 (18:05 +0100)]
Issue #14084: Fix a file descriptor leak when importing a module with a bad encoding.
Antoine Pitrou [Wed, 22 Feb 2012 17:03:04 +0000 (18:03 +0100)]
In find_module(), do not silence fileno() and dup() errors.
Antoine Pitrou [Wed, 22 Feb 2012 15:41:50 +0000 (16:41 +0100)]
Fix compile failure under Windows
Victor Stinner [Wed, 22 Feb 2012 12:55:02 +0000 (13:55 +0100)]
Optimize str%arg for number formats: %i, %d, %u, %x, %p
Write a specialized function to write an ASCII/latin1 C char* string into a
Python Unicode string.
Victor Stinner [Wed, 22 Feb 2012 12:37:39 +0000 (13:37 +0100)]
Micro-optimize computation of maxchar in PyUnicode_TransformDecimalToASCII()
Victor Stinner [Wed, 22 Feb 2012 12:37:04 +0000 (13:37 +0100)]
Micro-optimize unicode_expandtabs(): use FILL() macro to write N spaces
Victor Stinner [Wed, 22 Feb 2012 12:36:20 +0000 (13:36 +0100)]
PyUnicode_New() and unicode_putchar() check for MAX_UNICODE maximum (U+10FFFF)
Nadeem Vawda [Wed, 22 Feb 2012 09:53:09 +0000 (11:53 +0200)]
Merge: #14053: Fix "make patchcheck" to work with MQ.
Patch by Francisco Martín Brugué
Nadeem Vawda [Wed, 22 Feb 2012 09:46:41 +0000 (11:46 +0200)]
Issue #14053: Fix "make patchcheck" to work with MQ.
Patch by Francisco Martín Brugué
Ross Lagerwall [Wed, 22 Feb 2012 04:02:07 +0000 (06:02 +0200)]
Fix sporadic test_subprocess regression introduced by
834650d63130.
Antoine Pitrou [Wed, 22 Feb 2012 02:33:56 +0000 (03:33 +0100)]
Fix (presumably) test_hash under big-endian systems (PPC).
Antoine Pitrou [Wed, 22 Feb 2012 02:33:56 +0000 (03:33 +0100)]
Fix (presumably) test_hash under big-endian systems (PPC).
Antoine Pitrou [Wed, 22 Feb 2012 01:46:58 +0000 (02:46 +0100)]
Additional debug info in case of failure
Antoine Pitrou [Wed, 22 Feb 2012 01:30:09 +0000 (02:30 +0100)]
unload() should be sufficient
Antoine Pitrou [Wed, 22 Feb 2012 00:11:31 +0000 (01:11 +0100)]
Try to debug sporadic test failures
Benjamin Peterson [Tue, 21 Feb 2012 23:03:26 +0000 (18:03 -0500)]
remove unapplicable statement
Georg Brandl [Tue, 21 Feb 2012 21:37:36 +0000 (22:37 +0100)]
merge with 3.2
Georg Brandl [Tue, 21 Feb 2012 21:36:37 +0000 (22:36 +0100)]
merge with 3.2
Georg Brandl [Tue, 21 Feb 2012 21:36:27 +0000 (22:36 +0100)]
Remove reST markup from --help output. Also: O(n**2) is dict construction, not single insertion.
Victor Stinner [Tue, 21 Feb 2012 21:10:16 +0000 (22:10 +0100)]
site: don't import traceback at startup to speed up Python startup
Benjamin Peterson [Tue, 21 Feb 2012 21:08:05 +0000 (16:08 -0500)]
enable hash randomization by default
Martin v. Löwis [Tue, 21 Feb 2012 18:54:26 +0000 (19:54 +0100)]
Issue #12406: Update list of files.
Antoine Pitrou [Tue, 21 Feb 2012 18:18:10 +0000 (19:18 +0100)]
Actually run the new tests.
Antoine Pitrou [Tue, 21 Feb 2012 18:14:26 +0000 (19:14 +0100)]
Add a test that memoryviews have hash randomization enabled.
Antoine Pitrou [Tue, 21 Feb 2012 18:08:26 +0000 (19:08 +0100)]
Fix test failure in test_cmd_line by initializing the hash secret at the earliest point.
Antoine Pitrou [Tue, 21 Feb 2012 18:03:47 +0000 (19:03 +0100)]
Fix test failure in test_cmd_line by initializing the hash secret at the earliest point.
Martin v. Löwis [Tue, 21 Feb 2012 17:49:10 +0000 (18:49 +0100)]
Issue #12406: prevent case where shortened name could conflict with short name.
Martin v. Löwis [Tue, 21 Feb 2012 17:07:58 +0000 (18:07 +0100)]
merge 2.6
Martin v. Löwis [Tue, 21 Feb 2012 17:06:22 +0000 (18:06 +0100)]
Issue #6807: Run msisupport.mak earlier.
Martin v. Löwis [Tue, 21 Feb 2012 16:26:10 +0000 (17:26 +0100)]
merge 3.2
Martin v. Löwis [Tue, 21 Feb 2012 16:23:55 +0000 (17:23 +0100)]
Issue #10580: Minor grammar change in Windows installer.
Benjamin Peterson [Tue, 21 Feb 2012 16:12:14 +0000 (11:12 -0500)]
merge 3.2
Benjamin Peterson [Tue, 21 Feb 2012 16:09:13 +0000 (11:09 -0500)]
merge 3.2
Benjamin Peterson [Tue, 21 Feb 2012 16:08:50 +0000 (11:08 -0500)]
ensure no one tries to hash things before the random seed is found
Petri Lehtinen [Tue, 21 Feb 2012 11:59:34 +0000 (13:59 +0200)]
Merge branch '3.2'
Closes #8033.
Petri Lehtinen [Sun, 19 Feb 2012 19:38:00 +0000 (21:38 +0200)]
sqlite3: Fix 64-bit integer handling in user functions on 32-bit architectures
Closes #8033.
Ezio Melotti [Tue, 21 Feb 2012 07:29:10 +0000 (09:29 +0200)]
Merge the HTMLParser fix with 3.2.
Ezio Melotti [Tue, 21 Feb 2012 07:25:00 +0000 (09:25 +0200)]
HTMLParser is now able to handle slashes in the start tag.
Benjamin Peterson [Tue, 21 Feb 2012 03:35:25 +0000 (22:35 -0500)]
update unicode link
Benjamin Peterson [Tue, 21 Feb 2012 03:34:50 +0000 (22:34 -0500)]
adjust docs for unicode 6.1
Benjamin Peterson [Tue, 21 Feb 2012 03:24:29 +0000 (22:24 -0500)]
update to Unicode 6.1
Georg Brandl [Mon, 20 Feb 2012 23:50:13 +0000 (00:50 +0100)]
Forgot the "empty string -> hash == 0" special case for strings.
Georg Brandl [Mon, 20 Feb 2012 23:34:05 +0000 (00:34 +0100)]
Merge more test vs hashing-order fixes from 3.2.
Georg Brandl [Mon, 20 Feb 2012 23:33:36 +0000 (00:33 +0100)]
Merge 3.2: Issue #13703 plus some related test suite fixes.
Georg Brandl [Mon, 20 Feb 2012 23:32:36 +0000 (00:32 +0100)]
Disable an inspect test: it depends on dict ordering which parameter is reported as duplicate.
Antoine Pitrou [Mon, 20 Feb 2012 23:00:06 +0000 (00:00 +0100)]
Delete the iterator, which could accidentally keep a temporary reference to the yielded element.
Antoine Pitrou [Mon, 20 Feb 2012 22:51:50 +0000 (23:51 +0100)]
Merge
Georg Brandl [Mon, 20 Feb 2012 22:52:16 +0000 (23:52 +0100)]
Dummy-merge with 3.1
Georg Brandl [Mon, 20 Feb 2012 22:49:29 +0000 (23:49 +0100)]
Fix typo in conditional.
Antoine Pitrou [Mon, 20 Feb 2012 22:49:07 +0000 (23:49 +0100)]
Make "regrtest -j" "-R"-aware
Georg Brandl [Mon, 20 Feb 2012 22:37:36 +0000 (23:37 +0100)]
Fix obscure failures of datetime-related tests due to the datetime tests failing to restore the system state completely after testing the pure-Python versions.
Georg Brandl [Mon, 20 Feb 2012 22:09:59 +0000 (23:09 +0100)]
Fix typo.
Georg Brandl [Mon, 20 Feb 2012 21:48:06 +0000 (22:48 +0100)]
Fix dbm_gnu test relying on set order.
Georg Brandl [Mon, 20 Feb 2012 21:08:27 +0000 (22:08 +0100)]
Fix use of deprecated assertRegexpMatches method.
Antoine Pitrou [Mon, 20 Feb 2012 21:06:59 +0000 (22:06 +0100)]
Issue #14063: fix test_importlib failure under OS X case-insensitive filesystems
(regression)
Georg Brandl [Mon, 20 Feb 2012 21:06:02 +0000 (22:06 +0100)]
Remove setting hash seed to regrtest's random seed and re-execv()ing: this doesn't preserve Python flags and fails from a temp directory.
Georg Brandl [Mon, 20 Feb 2012 21:48:06 +0000 (22:48 +0100)]
Fix dbm_gnu test relying on set order.
Georg Brandl [Mon, 20 Feb 2012 22:09:59 +0000 (23:09 +0100)]
Fix typo.
Georg Brandl [Mon, 20 Feb 2012 22:49:29 +0000 (23:49 +0100)]
Fix typo in conditional.
Georg Brandl [Mon, 20 Feb 2012 21:06:02 +0000 (22:06 +0100)]
Remove setting hash seed to regrtest's random seed and re-execv()ing: this doesn't preserve Python flags and fails from a temp directory.
Georg Brandl [Mon, 20 Feb 2012 21:03:28 +0000 (22:03 +0100)]
Another test_dis dict order dependency.
Georg Brandl [Mon, 20 Feb 2012 20:43:25 +0000 (21:43 +0100)]
Merge with 3.1.
Georg Brandl [Mon, 20 Feb 2012 20:41:03 +0000 (21:41 +0100)]
Fix test_dis dependency on dict order.
Georg Brandl [Mon, 20 Feb 2012 20:37:22 +0000 (21:37 +0100)]
Fix use of deprecated assert_ method.
Georg Brandl [Mon, 20 Feb 2012 20:36:28 +0000 (21:36 +0100)]
Fix "sys.path modified" warning in test_strlit, by not replacing sys.path itself, only its contents.
Georg Brandl [Mon, 20 Feb 2012 20:34:57 +0000 (21:34 +0100)]
Fix bad inheritance in test_subprocess that led to a number of tests being executed twice.
Georg Brandl [Mon, 20 Feb 2012 20:34:31 +0000 (21:34 +0100)]
Run tests with -R on "make test" and the buildbots.
Georg Brandl [Mon, 20 Feb 2012 20:31:46 +0000 (21:31 +0100)]
Merge from 3.1: Issue #13703: add a way to randomize the hash values of basic types (str, bytes, datetime)
in order to make algorithmic complexity attacks on (e.g.) web apps much more complicated.
The environment variable PYTHONHASHSEED and the new command line flag -R control this
behavior.
Benjamin Peterson [Mon, 20 Feb 2012 20:20:37 +0000 (15:20 -0500)]
don't rely on the order of module clearing
Benjamin Peterson [Mon, 20 Feb 2012 20:06:35 +0000 (15:06 -0500)]
put docstrings on functions
Georg Brandl [Mon, 20 Feb 2012 18:54:16 +0000 (19:54 +0100)]
Issue #13703: add a way to randomize the hash values of basic types (str, bytes, datetime)
in order to make algorithmic complexity attacks on (e.g.) web apps much more complicated.
The environment variable PYTHONHASHSEED and the new command line flag -R control this
behavior.
Vinay Sajip [Mon, 20 Feb 2012 18:51:00 +0000 (18:51 +0000)]
Merged upstream changes.
Vinay Sajip [Mon, 20 Feb 2012 18:50:33 +0000 (18:50 +0000)]
Merged upstream changes.
Antoine Pitrou [Mon, 20 Feb 2012 18:46:26 +0000 (19:46 +0100)]
Fix use of assertRaises following
c760bd844222 (spotted by Alex Gaynor).
Antoine Pitrou [Mon, 20 Feb 2012 18:41:11 +0000 (19:41 +0100)]
Issue #14040: Remove rarely used file name suffixes for C extensions (under POSIX mainly).
This will improve import performance a bit (especially under importlib).
Vinay Sajip [Mon, 20 Feb 2012 18:36:12 +0000 (18:36 +0000)]
Merged documentation update from 3.2.
Vinay Sajip [Mon, 20 Feb 2012 18:35:26 +0000 (18:35 +0000)]
logging: clarified documentation for Handler.handleError.
Antoine Pitrou [Mon, 20 Feb 2012 18:30:23 +0000 (19:30 +0100)]
Issue #13641: Decoding functions in the base64 module now accept ASCII-only unicode strings.
Patch by Catalin Iacob.
Benjamin Peterson [Mon, 20 Feb 2012 14:02:57 +0000 (09:02 -0500)]
merge heads
Benjamin Peterson [Mon, 20 Feb 2012 13:48:25 +0000 (08:48 -0500)]
write versionadded
Antoine Pitrou [Mon, 20 Feb 2012 12:52:47 +0000 (13:52 +0100)]
_relax_case -> _make_relax_case
Benjamin Peterson [Mon, 20 Feb 2012 01:36:12 +0000 (20:36 -0500)]
check for NULL to fix segfault
Benjamin Peterson [Mon, 20 Feb 2012 01:02:57 +0000 (20:02 -0500)]
use new generic __dict__ descriptor implementations
Benjamin Peterson [Mon, 20 Feb 2012 00:59:10 +0000 (19:59 -0500)]
add generic implementation of a __dict__ descriptor for C types
Antoine Pitrou [Mon, 20 Feb 2012 00:52:17 +0000 (01:52 +0100)]
Merge
Éric Araujo [Mon, 20 Feb 2012 00:53:09 +0000 (01:53 +0100)]
Merge 3.2
Antoine Pitrou [Mon, 20 Feb 2012 00:48:16 +0000 (01:48 +0100)]
Issue #14043: Speed up importlib's _FileFinder by at least 8x, and add a new importlib.invalidate_caches() function.
importlib is now often faster than imp.find_module() at finding modules.
Éric Araujo [Mon, 20 Feb 2012 00:44:55 +0000 (01:44 +0100)]
Add missing “::” markup.
Also wrap two looong lines.
Brett Cannon [Mon, 20 Feb 2012 00:36:44 +0000 (19:36 -0500)]
Fix a failing importlib test under Windows.
Closes issue #14054.