Commit Graph

20181 Commits

Author SHA1 Message Date
Benjamin Peterson 6ddac006be put docstrings on functions 2012-02-20 15:06:35 -05:00
Antoine Pitrou dff46faa95 Fix use of assertRaises following c760bd844222 (spotted by Alex Gaynor). 2012-02-20 19:46:26 +01:00
Antoine Pitrou ea6b4d5f70 Issue #13641: Decoding functions in the base64 module now accept ASCII-only unicode strings.
Patch by Catalin Iacob.
2012-02-20 19:30:23 +01:00
Antoine Pitrou b67075beb5 _relax_case -> _make_relax_case 2012-02-20 13:52:47 +01:00
Antoine Pitrou c541f8ef40 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.
2012-02-20 01:48:16 +01:00
Brett Cannon 336b2f45e5 Fix a failing importlib test under Windows.
Closes issue #14054.
2012-02-19 19:36:44 -05:00
Benjamin Peterson 85c71ae882 fix test now that staticmethod and classmethod are bigger 2012-02-19 19:16:47 -05:00
Antoine Pitrou c135fa424e Fix last remaining build issues of _ssl under old OpenSSLs. Patch by Vinay. 2012-02-19 21:22:39 +01:00
Martin v. Löwis 7b77188e89 Create _attr/_attrNS lazily. 2012-02-19 20:55:05 +01:00
Martin v. Löwis 14aa280de2 Use __slots__ throughout instead of __dict__, to reduce the memory usage. 2012-02-19 20:25:12 +01:00
Benjamin Peterson b900d6a78c initialize __dict__ if needed 2012-02-19 10:17:30 -05:00
Benjamin Peterson 01d7eba316 allow arbitrary attributes on classmethod and staticmethod (closes #14051) 2012-02-19 01:10:25 -05:00
Jesus Cea 14ed7f23c2 Test for issue #13500 2012-02-19 03:52:23 +01:00
Charles-François Natali 3ccc918b4a Issue #14001: CVE-2012-0845: xmlrpc: Fix an endless loop in SimpleXMLRPCServer
upon malformed POST request.
2012-02-18 15:02:10 +01:00
Charles-François Natali cd96b4f1ff Issue #14001: CVE-2012-0845: xmlrpc: Fix an endless loop in SimpleXMLRPCServer
upon malformed POST request.
2012-02-18 14:53:41 +01:00
Charles-François Natali ec1712a166 Issue #14001: CVE-2012-0845: xmlrpc: Fix an endless loop in SimpleXMLRPCServer
upon malformed POST request.
2012-02-18 14:42:57 +01:00
Petri Lehtinen aa2c670ee6 Merge branch '3.2'
Closes #11689.
2012-02-17 21:36:52 +02:00
Petri Lehtinen c86d9e2846 Fix a variable scoping error in an sqlite3 test
Closes #11689.
2012-02-17 21:31:02 +02:00
Antoine Pitrou a9bf2ac726 Try to really fix compilation failures of the _ssl module under very old OpenSSLs. 2012-02-17 18:47:54 +01:00
Éric Araujo f1fd388c77 Branch merge 2012-02-17 18:10:11 +01:00
Éric Araujo 2180ee641c Fix code I unwittingly broke in b0e2d6592a1f (#14038) 2012-02-17 17:26:30 +01:00
Brett Cannon 082f177c67 Fix importlib.test.__main__ to only worry about command-line flags when directly executed. 2012-02-17 10:44:24 -05:00
Brett Cannon f2e86751cc Optimize importlib's case-sensitivity check by wasting as little time as possible under case-sensitive OSs. 2012-02-17 09:46:48 -05:00
Brett Cannon 1f14bebe3c Have importlib.test use argparse instead of some hacked up solution. 2012-02-17 09:37:39 -05:00
Brett Cannon ba17fe256e Have importlib use os.replace() for atomic renaming.
Closes issue #13961. Thanks to Charles-François Natali for the patch.
2012-02-17 09:26:53 -05:00
Brett Cannon f58d45c649 Tweak the handling of the empty string in sys.path for importlib.
It seems better to cache the finder for the cwd under its full path
insetad of '' in case the cwd changes. Otherwise FileFinder needs to
dynamically change itself based on whether it is given '' instead of
caching a finder for every change to the cwd.
2012-02-16 18:12:00 -05:00
Brett Cannon 22e7c88057 Merge 2012-02-16 18:03:47 -05:00
Brett Cannon 3b1a06c1ea importlib.__import__() now raises ValueError when level < 0.
This is to bring it more in line with what PEP 328 set out to do with
removing ambiguous absolute/relative import semantics.
2012-02-16 17:47:48 -05:00
Florent Xicluna 1639505c38 fix the _namespace_map cleanup for cElementTree tests. 2012-02-16 23:28:35 +01:00
Florent Xicluna e59a306081 The C accelerator was not always imported for cElementTree's tests. (there's still an issue with --huntrleaks switch) 2012-02-16 23:17:31 +01:00
Charles-François Natali 8e3926a810 Merge. 2012-02-16 19:54:48 +01:00
Charles-François Natali 4a72ebe34b Issue #13878: Fix random test_sched failures. 2012-02-16 19:51:45 +01:00
Charles-François Natali f670ca5e70 Issue #13878: Fix random test_sched failures. 2012-02-16 19:49:48 +01:00
Brett Cannon 7fab676e87 Refactor importlib.__import__() and _gcd_import() to facilitate using
an __import__ implementation that takes care of basics in C and punts
to importlib for more complicated code.
2012-02-16 13:43:41 -05:00
Éric Araujo e8c5fdba30 Add test for packaging.util.set_platform (#13974).
Patch by Tshepang Lekhonkhobe.
2012-02-16 19:32:17 +01:00
Eli Bendersky 292f9a891d make TestAccelerator[Not]Imported for ElementTree more robust 2012-02-16 19:55:29 +02:00
Eli Bendersky 66e6f8e525 Disabling a test that fails on some bots. Will investigate the failure soon 2012-02-16 18:08:44 +02:00
Gregory P. Smith 5b791fb548 Issue #2489: Fix bug in _copy loop that could consume 100% cpu on EOF. 2012-02-16 00:35:43 -08:00
Gregory P. Smith a124a688a2 don't use assertSameElements. 2012-02-16 00:34:12 -08:00
Gregory P. Smith 05f5953ab4 Issue #2489: Fix bug in _copy loop that could consume 100% cpu on EOF. 2012-02-16 00:29:12 -08:00
Eli Bendersky da57819efa in the tests of ElementTree, verify that the C accelerator is imported or not imported as expected 2012-02-16 06:52:39 +02:00
Victor Stinner 4aec77617f (Merge 3.2) Issue #13913: Another fix test_pep3120 for the UTF-8 codec name 2012-02-15 23:45:34 +01:00
Victor Stinner 5c724a804a Issue #13913: Another fix test_pep3120 for the UTF-8 codec name 2012-02-15 23:44:03 +01:00
Sandro Tosi cd77815e4c Issue #11836: document and expose multiprocessing.SimpleQueue 2012-02-15 23:27:00 +01:00
Victor Stinner 10e467c963 (Merge 3.2) Issue #13913: Fix test_pep3120 for the UTF-8 codec name 2012-02-15 22:25:51 +01:00
Victor Stinner 1303298d06 Issue #13913: Fix test_pep3120 for the UTF-8 codec name 2012-02-15 22:24:17 +01:00
Antoine Pitrou 482ee66cb7 Issue #7644: Add tests for the file argument of NNTP.head() and NNTP.body().
Patch by Hynek Schlawack.
2012-02-15 18:53:49 +01:00
Antoine Pitrou 2640b52237 Issue #7644: Add tests for the file argument of NNTP.head() and NNTP.body().
Patch by Hynek Schlawack.
2012-02-15 18:53:18 +01:00
Éric Araujo 43df889d63 Fix for packaging test failure on shared builds (#1326113) 2012-02-15 18:14:50 +01:00
Éric Araujo a76eff7db0 Merge fix from 3.2 2012-02-15 18:13:00 +01:00