Commit Graph

21641 Commits

Author SHA1 Message Date
Nick Coghlan 5ee9892406 Close #15425: Eliminate more importlib related traceback noise 2012-07-29 20:30:36 +10:00
Meador Inge bb9b1c165d Issue #15402: Simplify Struct.__sizeof__ and make tests more precise. 2012-07-28 22:32:50 -05:00
Meador Inge 90bc2dbcce Issue #15402: Simplify Struct.__sizeof__ and make tests more precise. 2012-07-28 22:16:39 -05:00
Martin v. Löwis e3010a8d12 Issue #14578: Support modules registered in the Windows registry again.
Patch by Amaury Forgeot d'Arc.
2012-07-28 21:33:05 +02:00
Richard Oudkerk 5562d9dc5d Issue #1692335: Move initial args assignment to BaseException.__new__
to help pickling of naive subclasses.
2012-07-28 17:45:28 +01:00
Stefan Krah 7d12d9df13 Issue #12834: Fix PyBuffer_ToContiguous() for non-contiguous arrays. 2012-07-28 12:25:55 +02:00
Ned Deily 6c779ea553 Issue #15364: Fix test_srcdir for the installed case. 2012-07-27 23:37:04 -07:00
Richard Oudkerk b15e622bb8 Issue #6056: Make multiprocessing use setblocking(True) on the sockets it uses.
Original patch by J Derek Wilson.
2012-07-27 14:19:00 +01:00
Richard Oudkerk 4887b1c0e7 Issue #6056: Make multiprocessing use setblocking(True) on the sockets it uses.
Original patch by J Derek Wilson.
2012-07-27 14:06:11 +01:00
Richard Oudkerk 46874ad367 Issue #15364: Fix sysconfig.get_config_var('srcdir') to be an absolute path. 2012-07-27 12:06:55 +01:00
Martin v. Löwis 3bbd2fad4d Issue #15456: Fix code __sizeof__ after #12399 change.
Patch by Serhiy Storchaka.
2012-07-26 22:23:23 +02:00
Jason R. Coombs d0118e16a1 Restored test by specifying that the symlink links to a target (currently required for Windows symlinks). See issue15093 for details. 2012-07-26 15:21:17 -04:00
Antoine Pitrou 0b9e7b9ea9 Issue #15320: Make iterating the list of tests thread-safe when running tests in multiprocess mode.
Patch by Chris Jerdonek.
2012-07-26 00:47:15 +02:00
Antoine Pitrou 09f2e6f902 Issue #15320: Make iterating the list of tests thread-safe when running tests in multiprocess mode.
Patch by Chris Jerdonek.
2012-07-26 00:45:19 +02:00
Martin v. Löwis 099414875b merge 3.2 2012-07-25 11:33:02 +02:00
Martin v. Löwis 30d5e6c13f Issue #7163: Propagate return value of sys.stdout.write.
Patch by Roger Serwy.
2012-07-25 11:32:26 +02:00
Martin v. Löwis f4b341b0e6 merge 3.2 2012-07-25 10:49:32 +02:00
Martin v. Löwis c882b7c51a Issue #15318: Prevent writing to sys.stdin.
Patch by Roger Serwy and myself.
2012-07-25 10:47:20 +02:00
Jesus Cea 653e4b30e3 MERGE: Better test for Issue #15402: Add a __sizeof__ method to struct.Struct 2012-07-23 18:16:18 +02:00
Jesus Cea 189fdf187b Better test for Issue #15402: Add a __sizeof__ method to struct.Struct 2012-07-23 18:15:33 +02:00
Meador Inge 9f65899d19 Issue #15402: Add a __sizeof__ method to struct.Struct.
Initial patch by Serhiy Storchaka.
2012-07-23 10:22:36 -05:00
Meador Inge b14d8c9bcf Issue #15402: Add a __sizeof__ method to struct.Struct.
Initial patch by Serhiy Storchaka.
2012-07-23 10:01:29 -05:00
R David Murray 970bef295d Merge #15232: correctly mangle From lines in MIME preamble and epilogue 2012-07-22 21:53:54 -04:00
R David Murray 6a31bc6d81 #15232: correctly mangle From lines in MIME preamble and epilogue 2012-07-22 21:47:53 -04:00
Ned Deily c7a5a76b1e Issue #15184: Some config variables in test_sysconfig_module
may differ between sysconfig and distutils.sysconfig due to
compiler customizations on OS X.  For now, move those vars
into a separate test and skip if the customization has taken
place in distutils.  The long-term solution is to eliminate
having two sysconfig modules.
2012-07-22 02:56:36 -07:00
Ned Deily 1ef871969c Issue #15184: Fix test__remove_unsupported_archs failures on 10.6
by removing unwarranted assumptions that clang compiler chain
cannot handle ppc (the driver passes off ppc compiles to gcc).
Mock the behavior instead.
2012-07-21 22:35:16 -07:00
Gregory P. Smith 34fcafde16 Consistently raise a TypeError when a non str is passed to hashlib.new
regardless of which of the two implementations of new is used.
2012-07-21 21:20:44 -07:00
Gregory P. Smith 76c28f7ce2 Consistently raise a TypeError when a non str is passed to hashlib.new
regardless of which of the two implementations of new is used.
2012-07-21 21:19:53 -07:00
R David Murray 45ccf032be Merge #13922: argparse no longer incorrectly strips '--' after the first one.
Patch by Jeff Knupp.
2012-07-21 22:56:49 -04:00
R David Murray 00528e8fec #13922: argparse no longer incorrectly strips '--' after the first one.
Patch by Jeff Knupp.
2012-07-21 22:48:35 -04:00
R David Murray d4703d1d85 Merge #12353: argparse now correctly handles null argument values.
Patch by Torsten Landschoff.
2012-07-21 22:28:08 -04:00
R David Murray b94082a71b #12353: argparse now correctly handles null argument values.
Patch by Torsten Landschoff.
2012-07-21 22:20:11 -04:00
R David Murray af418b2232 Merge #14391: clarify docstring discussion of Action's 'type' argument's value. 2012-07-21 17:05:24 -04:00
R David Murray 15cd9a0be4 #14391: clarify docstring discussion of Action's 'type' argument's value. 2012-07-21 17:04:25 -04:00
R David Murray 779b63d005 Merge #15342: Add clarifying sentence to posixpath.join docstring.
This sentence appears as a clarifying note in the HTML docs, and seems
worth having in the docstring since it covers a very common use case
that isn't otherwise obvious.  Thanks to Yongzhi Pan for the suggestion.
2012-07-21 14:34:51 -04:00
R David Murray e3de175a5e #15342: Add clarifying sentence to posixpath.join docstring.
This sentence appears as a clarifying note in the HTML docs, and seems
worth having in the docstring since it covers a very common use case
that isn't otherwise obvious.  Thanks to Yongzhi Pan for the suggestion.
2012-07-21 14:33:56 -04:00
Ned Deily 2731c049ac Issue #15184: Ensure configuration-related environment variables
are unset during test execution.
2012-07-21 09:29:54 -07:00
Brett Cannon 636601dfba Remove a relative import that escaped test.test_importlib. 2012-07-21 09:54:58 -04:00
Ned Deily df8aa2b325 Issue #15184: Ensure consistent results of OS X configuration
tailoring for universal builds by factoring out common OS X-specific
customizations from sysconfig, distutils.sysconfig, distutils.util,
and distutils.unixccompiler into a new module _osx_support that can
eventually also be used by packaging.
2012-07-21 05:36:30 -07:00
Florent Xicluna 0fd1062a76 Fix test_pprint random dict ordering. 2012-07-21 12:45:02 +02:00
Florent Xicluna 6e571d699f Fix test_pprint random dict ordering. 2012-07-21 12:44:20 +02:00
Florent Xicluna 6a01fc5d41 Issues #10017 and #14998: Fix TypeError using pprint on dictionaries with unorderable key. 2012-07-21 11:22:33 +02:00
Florent Xicluna d6da90f93d Issues #10017 and #14998: Fix TypeError using pprint on dictionaries with unorderable key. 2012-07-21 11:17:38 +02:00
Meador Inge da1ffbc4ee Issue #15409: Replace use of deprecated urllib.request.Request methods in http.cookijar
Patch by Flávio Ribeiro.
2012-07-20 19:12:04 -05:00
Antoine Pitrou 5e36edbaba Port additional tests from #14579 (the issue is already fixed). 2012-07-21 00:47:48 +02:00
Antoine Pitrou b4bbee25b1 Issue #14579: Fix CVE-2012-2135: vulnerability in the utf-16 decoder after error handling.
Patch by Serhiy Storchaka.
2012-07-21 00:45:14 +02:00
Brett Cannon ed19fcec89 Fix another import error. 2012-07-20 15:42:34 -04:00
Brett Cannon 86ae981da9 Fix an import from the importlib.test move. 2012-07-20 15:40:57 -04:00
Brett Cannon d382bfc921 Move importlib.test.benchmark to Tools/importbench to make it more
visible and to place it with other micro-benchmarks (e.g.
stringbench).
2012-07-20 14:54:53 -04:00
Brett Cannon 45a5e3afe5 Issue #15168: Move importlb.test to test.test_importlib.
This should make the Linux distros happy as it is now easier to leave
importlib's tests out of their base Python distribution.
2012-07-20 14:48:53 -04:00
Brett Cannon 4afc1c08d0 Merge 2012-07-20 14:22:27 -04:00
Brett Cannon 6ee9695270 Issue #15091: Call importlib.invalidate_caches() and reactivate a test
of importing a symlinked package.
2012-07-20 14:22:04 -04:00
Brett Cannon ba52586f76 Running the importlib tests from test_import is redundant as there is
no difference anymore between __import__ and importlib.__import__.
2012-07-20 14:01:34 -04:00
Meador Inge b17ad53e39 Issue #15406: Fix deprecation warning in ctypes test_bitfields.py
Patch by Flávio Ribeiro.
2012-07-20 12:52:42 -05:00
Meador Inge ca9652ea5d Issue #15406: Fix deprecation warning in ctypes test_bitfields.py
Patch by Flávio Ribeiro.
2012-07-20 12:48:34 -05:00
Nick Coghlan be7e49fd82 Close #15386: There was a loophole that meant importlib.machinery and imp would sometimes reference an uninitialised copy of importlib._bootstrap 2012-07-20 23:40:09 +10:00
Meador Inge 8fda359095 Issue #15401: Fix typo in inspect.getclosurevars docstring. 2012-07-19 21:33:21 -05:00
Hynek Schlawack 26fe37dd3f #1492704: Backout and wait for 3.4 2012-07-19 21:41:02 +02:00
Hynek Schlawack 77d3283370 #1492704: Make shutil.copyfile() raise a distinct SameFileError
Patch by Atsuo Ishimoto.
2012-07-19 20:23:49 +02:00
Meador Inge 7506dab2e8 Issue #6493: Fix handling of c_uint32 bitfields with width of 32 on Windows. 2012-07-19 00:14:35 -05:00
Meador Inge 60c2266afe Issue #6493: Fix handling of c_uint32 bitfields with width of 32 on Windows. 2012-07-19 00:01:22 -05:00
Nick Coghlan 76e077001d Close #15387: inspect.getmodulename() now uses a new importlib.machinery.all_suffixes() API rather than the deprecated inspect.getmoduleinfo() 2012-07-18 23:14:57 +10:00
Vinay Sajip 90db661b43 Closes #15307: symlinks now work on OS X with framework Python builds. Patch by Ronald Oussoren. 2012-07-17 17:33:46 +01:00
Hynek Schlawack 11718620ef Use posixpath.join() explicitely in posixpath.join() test
Used os.path.join before which has different semantics on Windows.
2012-07-17 14:29:33 +02:00
Hynek Schlawack 0b350c6b3e Use posixpath.join() explicitely in posixpath.join() test
Used os.path.join before which has different semantics on Windows.
2012-07-17 14:28:44 +02:00
Eli Bendersky f90fc68db4 fix whitespace woes 2012-07-17 15:09:56 +03:00
Eli Bendersky 43cc5f29a8 Optimize tostringlist by taking the stream class outside the function. It's now 2x faster on short calls. Related to #1767933 2012-07-17 15:09:12 +03:00
Nick Coghlan 9455492142 Issue #15314: Tweak a pkgutil test to hopefully be more Windows friendly 2012-07-17 21:37:58 +10:00
Hynek Schlawack 1815191f17 #15377: Make posixpath.join() more strict when checking for str/bytes mix
Based on a patch by Nick Coghlan.
2012-07-17 13:10:15 +02:00
Hynek Schlawack c5a4566922 #15377: Make posixpath.join() more strict when checking for str/bytes mix
Based on a patch by Nick Coghlan.
2012-07-17 13:05:43 +02:00
Nick Coghlan 9c3cf6b4a0 Merge Issue #15230 OS X buildbot fix from 3.2 2012-07-17 20:43:40 +10:00
Nick Coghlan eb3e62f1c8 Issue #15230: Attempt to make the OS X buildbots happy by resolving the tmp dir symlink in the test suite 2012-07-17 20:42:39 +10:00
Hynek Schlawack 1c4eb2c09a Fix context manager use in posixpath.join() tests
The asserts were useless (and buggy).
2012-07-17 10:50:30 +02:00
Hynek Schlawack 7cdc2bdd0d Fix context manager use in posixpath.join() tests
The asserts were useless (and buggy).
2012-07-17 10:48:19 +02:00
Eli Bendersky 426e248feb Preserve the invariant tostring(elem) == b''.join(tostringlist(elem)) and add a test to make sure it keeps working 2012-07-17 05:45:11 +03:00
Gregory P. Smith daa4c6b2e6 one more test fix for systems without select.poll. tested by deleting
select.poll before running.  works both ways (finally).  this should
fix the windows build.
2012-07-16 15:49:19 -07:00
Gregory P. Smith 954d46b2cc one more test fix for systems without select.poll. tested by deleting
select.poll before running.  works both ways (finally).  this should fix
the windows build.
2012-07-16 15:48:30 -07:00
Gregory P. Smith 49be9ed976 Fix unchecked select.poll reference in setUp and tearDown for
platforms that don't have it.
2012-07-16 13:39:10 -07:00
Gregory P. Smith ac14aa5187 Fix unchecked select.poll reference in setUp and tearDown for
platforms that don't have it.
2012-07-16 13:38:45 -07:00
Gregory P. Smith 2a86b25323 Fix the with_poll tests for platforms without poll. missing import. 2012-07-16 13:35:20 -07:00
Gregory P. Smith 5bcd005a0b Fix the with_poll tests for platforms without poll. missing import. 2012-07-16 13:34:50 -07:00
Vinay Sajip 8cffdd9ca2 Closes #15367: Corrected computation of include locations for source builds on Windows. Thanks to Richard Oudkerk for the bug report and patch. 2012-07-16 18:30:03 +01:00
Vinay Sajip 048b063780 Closes #15366: Corrected computation of include location for source builds. Thanks to Richard Oudkerk for the bug report and patch. 2012-07-16 18:24:55 +01:00
Hynek Schlawack c2d481fbcd #15238: Fix xattr related shutil.copystat tests
- Loosen up test as Fedora has implicit xattrs
- Actually test the destination for xattrs

Should make Fedora buildbot green again.
2012-07-16 17:11:10 +02:00
Gregory P. Smith 4866266bf4 Fixes Issue #14635: telnetlib will use poll() rather than select() when possible
to avoid failing due to the select() file descriptor limit.
2012-07-15 23:44:49 -07:00
Gregory P. Smith dad5711677 Fixes Issue #14635: telnetlib will use poll() rather than select() when possible
to avoid failing due to the select() file descriptor limit.
2012-07-15 23:42:26 -07:00
Ned Deily 274717757d Issue #13590: Improve support for OS X Xcode 4:
- fix test_distutils and test_sysconfig test failures by
  aligning sysconfig and distutils.sysconfig tailoring of
  configure variables (as in 2.7)
2012-07-15 21:30:03 -07:00
R David Murray 6159e0956c #4640: Add optparse tests for '-xxx' invalid when defining options.
Patch by Aaron (hac.man).
2012-07-15 20:12:24 -04:00
Vinay Sajip e554f8b858 Closes #15361: Corrected venv prompt in PowerShell activation script. 2012-07-15 21:58:13 +01:00
Larry Hastings b40380667c Issue #15202: Consistently use the name "follow_symlinks" for
new parameters in os and shutil functions.  Patch by Serhiy Storchaka.
2012-07-15 10:57:38 -07:00
Vinay Sajip 509d87d4a0 Issue #15307: Skipped test_venv:test_prefixes when run from a venv. 2012-07-15 16:12:54 +01:00
Hynek Schlawack 9ac4d8808f #15180: Clarify posixpath.join() error message when mixing str & bytes 2012-07-15 16:46:23 +02:00
Hynek Schlawack 4774946c3b #15180: Clarify posixpath.join() error message when mixing str & bytes 2012-07-15 16:21:30 +02:00
Nick Coghlan 8e6e7d39d3 Fix typo in a comment (noticed by Terry Reedy) 2012-07-15 23:13:18 +10:00
Nick Coghlan 9deaa06fe1 Issue #9319: Remove the workaround for this since fixed problem from pydoc 2012-07-15 22:17:02 +10:00
Nick Coghlan 2824cb507d Issue #15343: A lot more than just unicode decoding can go wrong when retrieving a source file 2012-07-15 22:12:14 +10:00
Nick Coghlan 8ecf50474c Issue #15343: Handle importlib.machinery.FileFinder instances in pkgutil.walk_packages (et al) 2012-07-15 21:19:18 +10:00
Nick Coghlan 3f94cbf9eb Actually initialize __main__.__loader__ with loader instances, not the corresponding type objects 2012-07-15 19:10:39 +10:00
Nick Coghlan 8dbe5b5568 Remove a statement that was only added for debugging purposes 2012-07-15 18:29:24 +10:00
Nick Coghlan 37b3b90b02 Note why we can't write an automated test for the code path that brings up the REPL for a bare 'python' call 2012-07-15 18:24:42 +10:00
Nick Coghlan 85e729ec3b Take the first step in resolving the messy pkgutil vs importlib edge cases by basing pkgutil explicitly on importlib, deprecating its internal import emulation and setting __main__.__loader__ correctly so that runpy still works (Affects #15343, #15314, #15357) 2012-07-15 18:09:52 +10:00
Eli Bendersky 00f402bfcb Close #1767933: Badly formed XML using etree and utf-16. Patch by Serhiy Storchaka, with some minor fixes by me 2012-07-15 06:02:22 +03:00
Larry Hastings ad5ae0456e - Issue #15238: shutil.copystat now copies Linux "extended attributes". 2012-07-14 17:55:11 -07:00
Nick Coghlan 2f54b98c8c Merge fix for #15230 from 3.2 2012-07-15 00:07:43 +10:00
Nick Coghlan 761bb11374 Close #15230: runpy.run_path now sets __package__ correctly. Also refactored the runpy tests to use a more systematic approach 2012-07-14 23:59:22 +10:00
Ned Deily 045bd5340f Issue #15241: Fix test_prefixes failure in test_venv due to symlink in
tempfile directory path (i.e. on OS X /tmp is actually /private/tmp).
2012-07-13 15:48:04 -07:00
Antoine Pitrou 26c01d7e05 Try other approach to fix issue #15334. 2012-07-13 22:49:55 +02:00
Antoine Pitrou 2bb3021837 Try other approach to fix issue #15334. 2012-07-13 22:46:41 +02:00
Antoine Pitrou b9c7c8260d Issue #15334: skip test_dynamic_key when run in non-interactive mode.
Patch by Jeremy Kloth.
2012-07-13 21:10:17 +02:00
Antoine Pitrou f0b1baf362 Issue #15334: skip test_dynamic_key when run in non-interactive mode.
Patch by Jeremy Kloth.
2012-07-13 21:08:41 +02:00
Antoine Pitrou c287423cb0 Merge 2012-07-13 20:59:35 +02:00
Antoine Pitrou c27ace688c Issue #15338: skip test_UNC_path when the current user doesn't have enough permissions to access the path. 2012-07-13 20:59:19 +02:00
Antoine Pitrou 68f4247b65 Issue #15338: skip test_UNC_path when the current user doesn't have enough permissions to access the path. 2012-07-13 20:54:42 +02:00
Brett Cannon a6473f9cfd Issues #15169, #14599: Make PyImport_ExecCodeModuleWithPathnames() use
Lib/imp.py for imp.source_from_cache() instead of its own C version.

Also change PyImport_ExecCodeModuleObject() to not infer the source
path from the bytecode path like
PyImport_ExecCodeModuleWithPathnames() does. This makes the function
less magical.

This also has the side-effect of removing all uses of MAXPATHLEN in
Python/import.c which can cause failures on really long filenames.
2012-07-13 13:57:03 -04:00
Antoine Pitrou 282083d5f4 Issue #15300: Ensure the temporary test working directories are in the same parent folder when running tests in multiprocess mode from a Python build.
Patch by Chris Jerdonek.
2012-07-11 19:19:14 +02:00
Martin v. Löwis 67097fd592 Use _RPCFile.write properly. 2012-07-11 09:17:15 +02:00
Martin v. Löwis c27616580d Don't use TextIOBase implementations in _RPCFile. 2012-07-11 08:48:34 +02:00
Martin v. Löwis 8a75bed317 Issue #15319: Revert wrapping of sys.stdin. Patch by Serhiy Storchaka. 2012-07-11 08:29:03 +02:00
Ned Deily c65ef9bf55 Issue #4832: Modify IDLE to save files with .py extension by
default on Windows and OS X as it already does with X11 Tk.
2012-07-09 18:16:11 -07:00
Eli Bendersky 8a80502d2c Issue #15296: Fix minidom.toxml/toprettyxml for non-unicode encodings. Patch by Serhiy Storchaka, with some minor style adjustments by me. 2012-07-13 09:52:39 +03:00
Antoine Pitrou 5df0204091 For diagnosis, try to list the directory first 2012-07-12 19:50:03 +02:00
Antoine Pitrou f189e80f23 Small improvements to test_unc_path 2012-07-12 19:48:49 +02:00
Antoine Pitrou 021548cf4c Try to fix or diagnose buildbot failures 2012-07-12 19:21:43 +02:00
Antoine Pitrou 673eb6a0bb Issue #15300: Ensure the temporary test working directories are in the same parent folder when running tests in multiprocess mode from a Python build.
Patch by Chris Jerdonek.
2012-07-11 19:21:31 +02:00
Martin v. Löwis fa0989fd38 merge 3.2 2012-07-11 09:17:54 +02:00
Martin v. Löwis ff40aa7b34 merge 3.2 2012-07-11 08:49:24 +02:00
Martin v. Löwis 9ba4545f97 merge 3.2 2012-07-11 08:29:55 +02:00
Brett Cannon 461c813164 Issue #15111: When a module was imported using a 'from import'
statement (e.g. ``from distutils import msvc9compiler``) that triggers
an ImportError of its own (e.g. the non-existence of winreg), let that
exception propagate instead of raising a generic ImportError for the
module being requested (e.g. msvc9compiler).
2012-07-10 10:05:00 -04:00
Martin v. Löwis 7d30b80a4e Issue #15315: Support VS 2010 in distutils cygwincompiler. 2012-07-10 07:07:06 +02:00
Brett Cannon 77b2abd094 Issue #15167 (as part of #13959): imp.get_magic() is no implemented in
Lib/imp.py.
2012-07-09 16:09:00 -04:00
Antoine Pitrou 59b9a7bc61 Backport test for nested namespace packages. 2012-07-09 21:23:58 +02:00
Antoine Pitrou b2dd880e0a Issue #15294: Fix a regression in pkgutil.extend_path()'s handling of nested namespace packages. 2012-07-09 21:23:58 +02:00
Martin v. Löwis 7df5e5858b merge 3.2 2012-07-09 20:53:03 +02:00
Martin v. Löwis 1d0f6dd7db normalize whitespace 2012-07-09 20:52:40 +02:00
Martin v. Löwis 79007fa05d merge 3.2 2012-07-09 20:48:56 +02:00
Martin v. Löwis 9ae3f7a189 Issue #13532: Check that arguments to sys.stdout.write are strings. 2012-07-09 20:46:11 +02:00
Brett Cannon 19a2f5961c Issue #15056: imp.cache_from_source() and source_from_cache() raise
NotimplementedError when sys.implementation.cache_tag is None.

Thanks to Pranav Ravichandran for taking an initial stab at the patch.
2012-07-09 13:58:07 -04:00
Brett Cannon bf7eab077f Issue #15256: Re-use the ImportError exception message as defined by
importlib._bootstrap in imp to fix a grammatical mistake.

Thanks to Marc Abramowitz for the patch.
2012-07-09 13:24:34 -04:00
Terry Jan Reedy cc4cffb8fa Merge with 3.2 Issue 12510 2012-07-09 00:15:14 -04:00
Terry Jan Reedy 44dea9d03f Issue 12510: Delete actual first param name for all methods; revise tests. 2012-07-09 00:13:21 -04:00
Senthil Kumaran 612a815820 revert the changes done for issue14826 - quoting witin Request is not desirable. 2012-07-08 18:00:47 -07:00
Senthil Kumaran 168456df11 revert the changes done for issue14826 - quoting witin Request is not desirable. 2012-07-08 17:47:25 -07:00
Amaury Forgeot d'Arc 1ced17dfe9 Issue #15110: Copy same docstring as other '_exec_module' methods. 2012-07-08 21:03:01 +02:00
Amaury Forgeot d'Arc ae7b8f07c1 Issue #15110: Also hide importlib frames when importing a builtin module fails. 2012-07-08 20:52:38 +02:00
Benjamin Peterson 9ed37433c4 test AST base type garbage collection 2012-07-08 11:13:36 -07:00
Vinay Sajip 4d378d8349 Closes #15281, #15283: Don't make venv scripts executable, but copy source mode instead, and provide better help for pyvenv. 2012-07-08 17:50:42 +01:00
Nick Coghlan 07c4e33c07 Issue 14814: The new systematic tests aren't just about error reporting any more - change names accordingly. Added and tweaked some example to ensure they were covering the intended code paths 2012-07-08 23:06:45 +10:00
Antoine Pitrou 88bf5ca63b Merge 2012-07-08 14:00:06 +02:00
Antoine Pitrou 5d62a61b58 Fix test_inspect messing up with linecache.cache. 2012-07-08 13:48:46 +02:00
Nick Coghlan 27396a1807 Issue 14814: Remove dead function (noticed by Serhiy Storchaka) 2012-07-08 21:38:12 +10:00
Antoine Pitrou 6803855ecf Fix test failure under Windows 2012-07-08 13:16:15 +02:00
Florent Xicluna 3f4ce635ee Issue #11022 and #15287: correctly remove the TESTFN file in test_builtin. 2012-07-08 12:08:45 +02:00
Antoine Pitrou bc07a5c913 Issue #15110: Fix the tracebacks generated by "import xxx" to not show the importlib stack frames. 2012-07-08 12:01:27 +02:00
Senthil Kumaran 25bfb529bd issue 14826 - Address the buildbot failure quote of url is the required change ( explanation msg164973) 2012-07-08 02:16:08 -07:00
Senthil Kumaran 45ce4dc73e issue 14826 - Address the buildbot failure ( explanation msg164973) 2012-07-08 02:08:48 -07:00
Ross Lagerwall 8d459f0cb8 #15284: Skip {send,recv}msg tests with disabled IPv6
Patch by Brian Brazil.
2012-07-08 09:53:57 +02:00
Nick Coghlan 297b143c6d Issue 14814: Further error case testing coverage and cleanups 2012-07-08 17:11:04 +10:00
Senthil Kumaran 540715a369 Fix issue14826 - make urllib.request.Request quoted url consistent with URLOpener open method.
Patch contributed by Stephen Thorne.
2012-07-07 17:15:52 -07:00
Senthil Kumaran b7451cecad Fix issue14826 - make urllib.request.Request quoted url consistent with URLOpener open method.
Patch contributed by Stephen Thorne.
2012-07-07 17:11:44 -07:00
Senthil Kumaran a5e0eaf2e1 Fix 5931 - Python runtime hardcoded in wsgiref.simple_server - Now it specifies an implementation specific term. 2012-07-07 14:29:58 -07:00
Łukasz Langa 31196dd7d0 Merge remote 2012-07-07 18:58:44 +02:00
Łukasz Langa cba243215e Fixes #14590: ConfigParser doesn't strip inline comment when delimiter occurs
earlier without preceding space.
2012-07-07 18:54:08 +02:00
Ross Lagerwall 5aa4354297 Merge with remote. 2012-07-07 18:42:57 +02:00
Ross Lagerwall 121d59ffa9 #15277: Fix a resource leak in support.py when IPv6 is disabled.
The leak occurred by setting:
echo 1 > /proc/sys/net/ipv6/conf/all/disable_ipv6
before running test_support.

Patch by Brian Brazil.
2012-07-07 18:40:32 +02:00
Florent Xicluna 61ea12c9a0 trace: remove unused imports. 2012-07-07 17:03:52 +02:00
Florent Xicluna 1917ea964e Add tests to marshall double with xmlrpc.client. 2012-07-07 17:03:25 +02:00
Florent Xicluna 109d57358e Issue #13248: io: Remove obsolete argument "max_buffer_size" of BufferedWriter and BufferedRWPair. 2012-07-07 17:03:22 +02:00
Florent Xicluna af1adbeedd Issue #13248: argparse: Remove obsolete argument "version" of ArgumentParser. 2012-07-07 17:02:22 +02:00
Nick Coghlan 3008ec070f Issue 14814: Ensure ordering semantics across all 3 entity types in ipaddress are consistent and well-defined 2012-07-08 00:45:33 +10:00
Nick Coghlan 9a9c28ce7a Issue 14814: Correctly return NotImplemented from ipaddress._BaseNetwork.__eq__ 2012-07-07 23:05:59 +10:00
Jesus Cea d46f7d209b Cope with OSs lying - #10142: Support for SEEK_HOLE/SEEK_DATA 2012-07-07 14:56:04 +02:00
Nick Coghlan b582ecc562 Issue 14814: Explain how to get more error detail in the ipaddress tutorial, and tweak the display for octet errors in IPv4 (noticed the formatting problem when adding to the docs) 2012-07-07 22:15:22 +10:00
Nick Coghlan 7319f69f49 Issue 14814: Make the ipaddress code easier to follow by using newer language features (patch by Serhiy Storchaka) 2012-07-07 21:43:30 +10:00
Florent Xicluna 79d79a0f29 Minor refactoring in importlib._bootstrap, and fix the '_wrap' docstring. 2012-07-07 13:16:44 +02:00
Florent Xicluna a1c974a66d Minor refactoring in xml.etree.ElementTree doctype parser. 2012-07-07 13:16:44 +02:00
Florent Xicluna fed2c51eea Merge branch 2012-07-07 12:26:56 +02:00
Florent Xicluna 11f0b41e9d Issue #14990: tokenize: correctly fail with SyntaxError on invalid encoding declaration. 2012-07-07 12:13:35 +02:00
Nick Coghlan 36f8dcde06 Issue 14814: Provide more informative error messages in ipaddress, and ensure that errors are caught as expected 2012-07-07 19:23:53 +10:00
Nick Coghlan 912238e3ac Issue 14814: %s implies coercion with str() - remove a lot of redundant str() calls from the ipaddress implementation 2012-07-07 13:34:50 +10:00
Antoine Pitrou 7d7f40c613 Issue #15247: FileIO now raises an error when given a file descriptor pointing to a directory. 2012-07-06 18:52:58 +02:00
Antoine Pitrou 9235b254dc Issue #15247: FileIO now raises an error when given a file descriptor pointing to a directory. 2012-07-06 18:48:24 +02:00
Nick Coghlan 5cf896fea8 Issue 14814: Eliminate bytes warnings from ipaddress by correctly throwing an exception early when given bytes data of the wrong length. Also removes 2.x backwards compatibility code from associated tests. 2012-07-07 01:43:31 +10:00
Nick Coghlan 3c2570caf2 Issue 14814: Better handling of cases where octet/hextet parsing fails, including ensuring that tracebacks are still clean even when calling class constructors directly 2012-07-07 01:13:55 +10:00
Richard Oudkerk 2240ac1eae Issue #15261: Stop os.stat(fd) crashing on Windows when fd not open. 2012-07-06 12:05:32 +01:00
Senthil Kumaran f28fbabc7f Fix issue # 15033 - Return the proper exitcode for failure when modules are invoked using -m switch. Patch contributed by Jeff Knupp 2012-07-04 19:33:45 -07:00
Senthil Kumaran f01a337950 Fix issue # 15033 - Return the proper exitcode for failure when modules are invoked using -m switch. Patch contributed by Jeff Knupp 2012-07-04 19:28:16 -07:00
Brett Cannon 53089c6e91 Issue #15210: Greatly simplify the test for supporting importlib
working without _frozen_importlib by moving to an import over a direct
access in sys.modules.
2012-07-04 14:03:40 -04:00
Vinay Sajip ed1f7c834f Closes #14902: Fixed timezone conversion of a date/time in the past. Thanks to Yuriy Syrovetskiy for the report and Juancarlo Añez for the patch on which this fix is based. 2012-07-03 21:36:36 +01:00
Vinay Sajip 3874e547b4 Issue #15241: Added test for venv prefixes. 2012-07-03 16:56:40 +01:00
Vinay Sajip abd344cbab Issue 15241: Improved site.py documentation relating to venvs. 2012-07-03 16:33:57 +01:00
Brett Cannon 98979b85e7 Issue #15166: Re-implement imp.get_tag() using sys.implementation.
Also eliminates some C code in Python/import.c as well.

Patch by Eric Snow with verification by comparing against another
patch from Jeff Knupp.
2012-07-02 15:13:11 -04:00
Brett Cannon 8e2f5564b3 Issue #15210: If _frozen_importlib is not found in sys.modules by
importlib.__init__, then catch the KeyError raised, not ImportError.
2012-07-02 14:53:10 -04:00
Brett Cannon 1e331560ee Closes #15030: Make importlib.abc.PyPycLoader respect the new .pyc
file size header field.

Thanks to Marc Abramowitz and Ronan Lamy for helping out with various
parts of the patch.
2012-07-02 14:35:34 -04:00
Antoine Pitrou f87289bb58 Issue #15229: An OSError subclass whose __init__ doesn't call back
OSError.__init__ could produce incomplete instances, leading to crashes
when calling str() on them.
2012-06-30 23:37:47 +02:00
doko@ubuntu.com 7e6c2e2cc4 - Issue #14330: For cross builds, don't use host python, use host search paths
for host compiler.

  Add NEWS entry, rename _PROJECT_BASE to _PYTHON_PROJECT_BASE.
2012-06-30 22:35:00 +02:00
doko@ubuntu.com 1abe1c5fe1 - Issue #14330: For cross builds, don't use host python, use host search paths
for host compiler.
2012-06-30 20:42:45 +02:00
Antoine Pitrou f93b705bd0 Issue #9239: add tests for modifying zipfile comments in append mode. 2012-06-30 17:32:41 +02:00
Antoine Pitrou c399185fcc Issue #9239: add tests for modifying zipfile comments in append mode. 2012-06-30 17:31:37 +02:00
Antoine Pitrou 24ef3e967f Issue #15225: improve error message when hmac is passed a wrong key type.
Patch by Marc Abramowitz.
2012-06-30 17:27:56 +02:00
Nadeem Vawda 83a4dd3fdf Update GzipFile docstring to mention gzip.open()'s new text-mode support. 2012-06-30 13:34:28 +02:00