]> granicus.if.org Git - python/log
python
9 years agoAdd early-out for the common case where kwds is NULL (gives 1.1% speedup).
Raymond Hettinger [Thu, 4 Feb 2016 10:46:16 +0000 (02:46 -0800)]
Add early-out for the common case where kwds is NULL (gives 1.1% speedup).

9 years agoMerge 3.5 (issue #25660)
Yury Selivanov [Thu, 4 Feb 2016 06:24:56 +0000 (01:24 -0500)]
Merge 3.5 (issue #25660)

9 years agoIssue #25660: Fix TAB key behaviour in REPL.
Yury Selivanov [Thu, 4 Feb 2016 06:23:05 +0000 (01:23 -0500)]
Issue #25660: Fix TAB key behaviour in REPL.

9 years agoMerge with 3.5
Zachary Ware [Thu, 4 Feb 2016 04:07:08 +0000 (22:07 -0600)]
Merge with 3.5

9 years agoPython for .NET has moved to Github.
Zachary Ware [Thu, 4 Feb 2016 04:05:46 +0000 (22:05 -0600)]
Python for .NET has moved to Github.

Reported by Denis Akhiyarov on docs@

9 years agoMerge with 3.5
Zachary Ware [Tue, 2 Feb 2016 23:04:56 +0000 (17:04 -0600)]
Merge with 3.5

9 years agoFix typo.
Zachary Ware [Tue, 2 Feb 2016 23:04:41 +0000 (17:04 -0600)]
Fix typo.

Reported by Jon Tetlak on docs@

9 years agoIssue #25945: Fixed bugs in functools.partial.
Serhiy Storchaka [Tue, 2 Feb 2016 16:45:47 +0000 (18:45 +0200)]
Issue #25945: Fixed bugs in functools.partial.
Fixed a crash when unpickle the functools.partial object with wrong state.
Fixed a leak in failed functools.partial constructor.
"args" and "keywords" attributes of functools.partial have now always types
tuple and dict correspondingly.

9 years agoIssue #26244: Merge zlib documentation from 3.5
Martin Panter [Wed, 3 Feb 2016 07:52:06 +0000 (07:52 +0000)]
Issue #26244: Merge zlib documentation from 3.5

9 years agoIssue #26244: Clarify default zlib compression level in documentation
Martin Panter [Wed, 3 Feb 2016 07:06:33 +0000 (07:06 +0000)]
Issue #26244: Clarify default zlib compression level in documentation

Based on patch by Aviv Palivoda.

9 years agoIssue #24421: Compile _math.c separately to avoid race condition
Martin Panter [Wed, 3 Feb 2016 05:19:44 +0000 (05:19 +0000)]
Issue #24421: Compile _math.c separately to avoid race condition

9 years agoIssue #25945: Fixed bugs in functools.partial.
Serhiy Storchaka [Tue, 2 Feb 2016 16:45:17 +0000 (18:45 +0200)]
Issue #25945: Fixed bugs in functools.partial.
Fixed a crash when unpickle the functools.partial object with wrong state.
Fixed a leak in failed functools.partial constructor.
"args" and "keywords" attributes of functools.partial have now always types
tuple and dict correspondingly.

9 years agomerge
Raymond Hettinger [Tue, 2 Feb 2016 05:21:19 +0000 (21:21 -0800)]
merge

9 years agoIssue #26194: Inserting into a full deque to raise an IndexError
Raymond Hettinger [Tue, 2 Feb 2016 05:19:22 +0000 (21:19 -0800)]
Issue #26194:  Inserting into a full deque to raise an IndexError

9 years agoMerge 3.5 (asyncio)
Victor Stinner [Mon, 1 Feb 2016 11:47:15 +0000 (12:47 +0100)]
Merge 3.5 (asyncio)

9 years agoFix error message in asyncio.selector_events.
Victor Stinner [Mon, 1 Feb 2016 11:46:38 +0000 (12:46 +0100)]
Fix error message in asyncio.selector_events.

Patch written by Carlo Beccarini <hackdiablo.cb@gmail.com>.

9 years agoMerge 3.5 (test_asyncio)
Victor Stinner [Mon, 1 Feb 2016 11:41:24 +0000 (12:41 +0100)]
Merge 3.5 (test_asyncio)

9 years agoIssue #19587: Merge test_bytes cleanup from 3.5
Martin Panter [Tue, 2 Feb 2016 10:54:10 +0000 (10:54 +0000)]
Issue #19587: Merge test_bytes cleanup from 3.5

9 years agoIssue #19587: Remove masked and redundant tests in test_bytes
Martin Panter [Tue, 2 Feb 2016 10:37:15 +0000 (10:37 +0000)]
Issue #19587: Remove masked and redundant tests in test_bytes

* test_contains() did not override anything
* test_expandtabs/upper/lower() in FixedStringTest were masking usable tests
  in string_tests. These tests now get run for bytearray() and bytes().
* test_expandtabs/upper/lower() in buffer_tests were only run on bytearray()
  and are redundant with string_tests

9 years agoIssue #26173: Merge SSL tests from 3.5
Martin Panter [Mon, 1 Feb 2016 22:13:43 +0000 (22:13 +0000)]
Issue #26173: Merge SSL tests from 3.5

9 years agoIssue #26173: Separate bad cert file tests and client rejection test
Martin Panter [Mon, 1 Feb 2016 21:58:11 +0000 (21:58 +0000)]
Issue #26173: Separate bad cert file tests and client rejection test

Test test_wrong_cert() runs a server that rejects the client's certificate,
so ECONNRESET is reasonable in addition to SSLError. On the other hand, the
other three tests don't even need to run a server because they are just
testing the parsing of invalid certificate files.

Also fix a ResourceWarning by closing the wrapped socket.

9 years agotest_asyncio: fix test_timeout_time()
Victor Stinner [Mon, 1 Feb 2016 11:39:50 +0000 (12:39 +0100)]
test_asyncio: fix test_timeout_time()

Accept time delta up to 0.12 second, instead of 0.11, for the "AMD64 FreeBSD
9.x" buildbot slave.

9 years agoMerge 3.5 (doc)
Victor Stinner [Sun, 31 Jan 2016 17:36:52 +0000 (18:36 +0100)]
Merge 3.5 (doc)

9 years agoEnhance os.scandir() doc
Victor Stinner [Sun, 31 Jan 2016 17:36:41 +0000 (18:36 +0100)]
Enhance os.scandir() doc

Issue #26248, patch written by Ben Hoyt:

1) Clarify that the return values of is_dir()/is_file()/etc are cached
   separately for follow_symlinks True and False.
2) Be more specific about when the functions require a system call, and how it
   relates to caching and follow_symlinks.
3) DRY up common stuff between is_dir and is_file by saying "Caching, system
   calls made, and exceptions raised are as per is_dir" in is_file.
4) Tweak to the first paragraph of docs for is_dir/is_file to simplify: assume
   the follow_symlinks=True default, then note the follow_symlinks=False
   non-default case after.

9 years agoIssue #23601: Use small object allocator for dict key objects
Raymond Hettinger [Sun, 31 Jan 2016 16:56:21 +0000 (08:56 -0800)]
Issue #23601:  Use small object allocator for dict key objects

9 years agoIssue #26242: Fix another one in importlib.rst
Berker Peksag [Sat, 30 Jan 2016 17:30:22 +0000 (19:30 +0200)]
Issue #26242: Fix another one in importlib.rst

9 years agoIssue #26242: Fix another one in importlib.rst
Berker Peksag [Sat, 30 Jan 2016 17:30:06 +0000 (19:30 +0200)]
Issue #26242: Fix another one in importlib.rst

9 years agoFix a markup error in socket.rst
Berker Peksag [Sat, 30 Jan 2016 17:23:46 +0000 (19:23 +0200)]
Fix a markup error in socket.rst

9 years agoFix a markup error in socket.rst
Berker Peksag [Sat, 30 Jan 2016 17:23:29 +0000 (19:23 +0200)]
Fix a markup error in socket.rst

9 years agoIssue #23076: Path.glob() now raises a ValueError if it's called with an
Berker Peksag [Sat, 30 Jan 2016 15:51:35 +0000 (17:51 +0200)]
Issue #23076: Path.glob() now raises a ValueError if it's called with an
invalid pattern.

Patch by Thomas Nyberg.

9 years agoIssue #23076: Path.glob() now raises a ValueError if it's called with an
Berker Peksag [Sat, 30 Jan 2016 15:50:48 +0000 (17:50 +0200)]
Issue #23076: Path.glob() now raises a ValueError if it's called with an
invalid pattern.

Patch by Thomas Nyberg.

9 years agoSimply docstrings of venv module
Berker Peksag [Sat, 30 Jan 2016 10:34:12 +0000 (12:34 +0200)]
Simply docstrings of venv module

This will hopefully make maintenance of venv documentation easier.
For example, see commits a4f0d76af176 and 5764cc02244d.

This patch has been reviewed by Vinaj Sajip, the maintainer of
venv module.

9 years agoUpdate "Creating Virtual Environments" link in venv documentation
Berker Peksag [Sat, 30 Jan 2016 10:24:49 +0000 (12:24 +0200)]
Update "Creating Virtual Environments" link in venv documentation

9 years agoUpdate "Creating Virtual Environments" link in venv documentation
Berker Peksag [Sat, 30 Jan 2016 10:24:31 +0000 (12:24 +0200)]
Update "Creating Virtual Environments" link in venv documentation

9 years agoUpdate output of venv -h
Berker Peksag [Sat, 30 Jan 2016 10:17:29 +0000 (12:17 +0200)]
Update output of venv -h

* Update description of the --system-site-packages option
* Show --copies option in the usage

9 years agoIssue #4806: Merge * unpacking fix from 3.5
Martin Panter [Sun, 31 Jan 2016 06:33:16 +0000 (06:33 +0000)]
Issue #4806: Merge * unpacking fix from 3.5

9 years agoIssue #4806: Avoid masking original TypeError in call with * unpacking
Martin Panter [Sun, 31 Jan 2016 06:30:56 +0000 (06:30 +0000)]
Issue #4806: Avoid masking original TypeError in call with * unpacking

Based on patch by Hagen Fürstenau and Daniel Urban.

9 years agoUpdate output of venv -h
Berker Peksag [Sat, 30 Jan 2016 10:17:10 +0000 (12:17 +0200)]
Update output of venv -h

* Update description of the --system-site-packages option
* Show --copies option in the usage

9 years agoIssue #25934: Merge with 3.5
Zachary Ware [Sat, 30 Jan 2016 01:09:41 +0000 (19:09 -0600)]
Issue #25934: Merge with 3.5

9 years agoIssue #26173: Merge wrongcert test from 3.5
Martin Panter [Sat, 30 Jan 2016 04:45:02 +0000 (04:45 +0000)]
Issue #26173: Merge wrongcert test from 3.5

9 years agoIssue #26173: Fix test_ssl confusion with non-existing cert and wrongcert.pem
Martin Panter [Sat, 30 Jan 2016 03:41:43 +0000 (03:41 +0000)]
Issue #26173: Fix test_ssl confusion with non-existing cert and wrongcert.pem

Testing for a non-existing certificate file is already done in test_errors().
Copy wrongcert.pem from Python 2 and use it to test the behaviour with a
mismatched certificate.

9 years agoIssue #25934: Default to /fp:strict for ICC builds
Zachary Ware [Sat, 30 Jan 2016 01:08:55 +0000 (19:08 -0600)]
Issue #25934: Default to /fp:strict for ICC builds

9 years agoIssue #26202: copy.deepcopy() now correctly copies range() objects with
Serhiy Storchaka [Thu, 28 Jan 2016 19:43:51 +0000 (21:43 +0200)]
Issue #26202: copy.deepcopy() now correctly copies range() objects with
non-atomic attributes.

9 years agoIssue #26202: copy.deepcopy() now correctly copies range() objects with
Serhiy Storchaka [Thu, 28 Jan 2016 19:43:35 +0000 (21:43 +0200)]
Issue #26202: copy.deepcopy() now correctly copies range() objects with
non-atomic attributes.

9 years agoIssue #19883: Fixed possible integer overflows in zipimport.
Serhiy Storchaka [Thu, 28 Jan 2016 19:32:39 +0000 (21:32 +0200)]
Issue #19883: Fixed possible integer overflows in zipimport.

9 years agoIssue #19883: Fixed possible integer overflows in zipimport.
Serhiy Storchaka [Thu, 28 Jan 2016 19:30:16 +0000 (21:30 +0200)]
Issue #19883: Fixed possible integer overflows in zipimport.

9 years agoNull merge
Serhiy Storchaka [Thu, 28 Jan 2016 17:57:04 +0000 (19:57 +0200)]
Null merge

9 years agoMerge heads
Serhiy Storchaka [Thu, 28 Jan 2016 17:56:40 +0000 (19:56 +0200)]
Merge heads

9 years agoIssue #26198: Added tests for "es", "et", "es#", "et#" and "C" format units
Serhiy Storchaka [Thu, 28 Jan 2016 17:51:26 +0000 (19:51 +0200)]
Issue #26198: Added tests for "es", "et", "es#", "et#" and "C" format units
of PyArg_Parse*() functions.

9 years agoIssue #26198: Added tests for "es", "et", "es#", "et#" and "C" format units
Serhiy Storchaka [Thu, 28 Jan 2016 17:49:54 +0000 (19:49 +0200)]
Issue #26198: Added tests for "es", "et", "es#", "et#" and "C" format units
of PyArg_Parse*() functions.

9 years agoNull merge 3.5
Victor Stinner [Thu, 28 Jan 2016 17:14:38 +0000 (18:14 +0100)]
Null merge 3.5

9 years agoBackport fixes on test_eintr
Victor Stinner [Thu, 28 Jan 2016 17:13:45 +0000 (18:13 +0100)]
Backport fixes on test_eintr

* Issue #25234: Skip test_eintr.test_open() under OS X to avoid hanging
* Issue #25868: Try to make test_eintr.test_sigwaitinfo() more reliable
  especially on slow buildbots. Use a pipe to synchronize the parent and the
  child processes.

9 years agoIssue #24705: Add a test case for ef84d21f5292
Berker Peksag [Thu, 28 Jan 2016 14:58:23 +0000 (16:58 +0200)]
Issue #24705: Add a test case for ef84d21f5292

9 years agoIssue #24705: Add a test case for ef84d21f5292
Berker Peksag [Thu, 28 Jan 2016 14:58:00 +0000 (16:58 +0200)]
Issue #24705: Add a test case for ef84d21f5292

9 years agoMerge 3.5: Issue #26227
Victor Stinner [Thu, 28 Jan 2016 14:44:10 +0000 (15:44 +0100)]
Merge 3.5: Issue #26227

9 years agoWindows: Decode hostname from ANSI code page
Victor Stinner [Thu, 28 Jan 2016 14:41:01 +0000 (15:41 +0100)]
Windows: Decode hostname from ANSI code page

Issue #26227: On Windows, getnameinfo(), gethostbyaddr() and gethostbyname_ex()
functions of the socket module now decode the hostname from the ANSI code page
rather than UTF-8.

9 years agoAdd a link to PEP 384 in stable.rst
Berker Peksag [Thu, 28 Jan 2016 10:42:45 +0000 (12:42 +0200)]
Add a link to PEP 384 in stable.rst

9 years agoIssue #19023: Merge ctypes doc and tests from 3.5
Martin Panter [Fri, 29 Jan 2016 10:25:40 +0000 (10:25 +0000)]
Issue #19023: Merge ctypes doc and tests from 3.5

9 years agoIssue #19023: Document ctypes array and pointer classes
Martin Panter [Fri, 29 Jan 2016 10:12:19 +0000 (10:12 +0000)]
Issue #19023: Document ctypes array and pointer classes

Also add some more tests. Based on patch by Sye van der Veen.

9 years agoAdd a link to PEP 384 in stable.rst
Berker Peksag [Thu, 28 Jan 2016 10:42:26 +0000 (12:42 +0200)]
Add a link to PEP 384 in stable.rst

9 years agoIssue #26034: Improve wording of clear parameter
Berker Peksag [Thu, 28 Jan 2016 07:13:32 +0000 (09:13 +0200)]
Issue #26034: Improve wording of clear parameter

9 years agoIssue #26034: Improve wording of clear parameter
Berker Peksag [Thu, 28 Jan 2016 07:13:14 +0000 (09:13 +0200)]
Issue #26034: Improve wording of clear parameter

9 years agoIssue #26034: Sync documentation of --clear with its behavior
Berker Peksag [Thu, 28 Jan 2016 07:01:49 +0000 (09:01 +0200)]
Issue #26034: Sync documentation of --clear with its behavior

Most of the docs has already been updated in c3c188a0325a.

9 years agoIssue #26034: Sync documentation of --clear with its behavior
Berker Peksag [Thu, 28 Jan 2016 07:01:26 +0000 (09:01 +0200)]
Issue #26034: Sync documentation of --clear with its behavior

Most of the docs has already been updated in c3c188a0325a.

9 years agoIssue #26199: Fix broken link in unittest.mock-examples.rst
Berker Peksag [Thu, 28 Jan 2016 06:40:21 +0000 (08:40 +0200)]
Issue #26199: Fix broken link in unittest.mock-examples.rst

Patch by Raphael Das Gupta.

9 years agoIssue #26220: Merge Unicode how-to from 3.5
Martin Panter [Fri, 29 Jan 2016 04:06:49 +0000 (04:06 +0000)]
Issue #26220: Merge Unicode how-to from 3.5

9 years agoIssue #26220: Remove outdated comment about a question mark
Martin Panter [Fri, 29 Jan 2016 04:01:16 +0000 (04:01 +0000)]
Issue #26220: Remove outdated comment about a question mark

9 years agoIssue #26199: Fix broken link in unittest.mock-examples.rst
Berker Peksag [Thu, 28 Jan 2016 06:40:03 +0000 (08:40 +0200)]
Issue #26199: Fix broken link in unittest.mock-examples.rst

Patch by Raphael Das Gupta.

9 years agoMerge with 3.5
Terry Jan Reedy [Wed, 27 Jan 2016 16:52:13 +0000 (11:52 -0500)]
Merge with 3.5

9 years agoIssue #25507: revert incorrect movement of idleConf import in c548ad75160c.
Terry Jan Reedy [Wed, 27 Jan 2016 16:51:50 +0000 (11:51 -0500)]
Issue #25507: revert incorrect movement of idleConf import in c548ad75160c.
Augment htest to include all major IOBinding functions.

9 years agoMerge 3.5
Victor Stinner [Wed, 27 Jan 2016 16:01:13 +0000 (17:01 +0100)]
Merge 3.5

9 years agoFix resize_compact()
Victor Stinner [Wed, 27 Jan 2016 15:56:53 +0000 (16:56 +0100)]
Fix resize_compact()

Issue #26217: resize_compact() must set wstr_length to 0 after freeing the wstr
string. Otherwise, an assertion fails in _PyUnicode_CheckConsistency().

9 years agomerge
Raymond Hettinger [Wed, 27 Jan 2016 05:46:03 +0000 (21:46 -0800)]
merge

9 years agoIssue #26194: Fix undefined behavior for deque.insert() when len(d) == maxlen
Raymond Hettinger [Wed, 27 Jan 2016 05:44:16 +0000 (21:44 -0800)]
Issue #26194: Fix undefined behavior for deque.insert() when len(d) == maxlen

9 years agoIssue #26146: enhance ast.Constant error message
Victor Stinner [Tue, 26 Jan 2016 23:39:12 +0000 (00:39 +0100)]
Issue #26146: enhance ast.Constant error message

Mention the name of the invalid type in error message of AST validation for
constants.

Suggestion made by Joseph Jevnik on a review.

9 years agoIssue #26146: remove useless code
Victor Stinner [Tue, 26 Jan 2016 23:37:59 +0000 (00:37 +0100)]
Issue #26146: remove useless code

obj2ast_constant() code is baesd on obj2ast_object() which has a special case
for Py_None. But in practice, we don't need to have a special case for
constants.

Issue noticed by Joseph Jevnik on a review.

9 years agoFix a refleak in validate_constant()
Victor Stinner [Tue, 26 Jan 2016 23:11:47 +0000 (00:11 +0100)]
Fix a refleak in validate_constant()

Issue #26146.

9 years agoFix typo
Raymond Hettinger [Tue, 26 Jan 2016 07:00:21 +0000 (23:00 -0800)]
Fix typo

9 years agomerge from 3.5
Senthil Kumaran [Tue, 26 Jan 2016 02:54:37 +0000 (18:54 -0800)]
merge from 3.5

Remove unnecessary test case comment in urllib.parse.py. These are asserted as test cases.

9 years agoRemove unnecessary test case comment in urllib.parse.py. These are asserted as test...
Senthil Kumaran [Tue, 26 Jan 2016 02:53:34 +0000 (18:53 -0800)]
Remove unnecessary test case comment in urllib.parse.py. These are asserted as test cases.

9 years agoAdd ast.Constant
Victor Stinner [Mon, 25 Jan 2016 23:40:57 +0000 (00:40 +0100)]
Add ast.Constant

Issue #26146: Add a new kind of AST node: ast.Constant. It can be used by
external AST optimizers, but the compiler does not emit directly such node.

An optimizer can replace the following AST nodes with ast.Constant:

* ast.NameConstant: None, False, True
* ast.Num: int, float, complex
* ast.Str: str
* ast.Bytes: bytes
* ast.Tuple if items are constants too: tuple
* frozenset

Update code to accept ast.Constant instead of ast.Num and/or ast.Str:

* compiler
* docstrings
* ast.literal_eval()
* Tools/parser/unparse.py

9 years agoTests versus zero are more compact than tests versus -1.
Raymond Hettinger [Mon, 25 Jan 2016 18:33:30 +0000 (10:33 -0800)]
Tests versus zero are more compact than tests versus -1.

9 years agoFix compiler warning about obviously unreachable code.
Raymond Hettinger [Mon, 25 Jan 2016 06:15:20 +0000 (22:15 -0800)]
Fix compiler warning about obviously unreachable code.

9 years agoConvert another post-decrement while-loop to pre-decrement for consistency
Raymond Hettinger [Sun, 24 Jan 2016 20:40:42 +0000 (12:40 -0800)]
Convert another post-decrement while-loop to pre-decrement for consistency
and better generated code (on both GCC and CLang).

9 years agoConvert two other post-decrement while-loops to pre-decrements for consistency
Raymond Hettinger [Sun, 24 Jan 2016 19:32:07 +0000 (11:32 -0800)]
Convert two other post-decrement while-loops to pre-decrements for consistency
and for better code generation.

9 years agoMiscellaneous refactorings
Raymond Hettinger [Sun, 24 Jan 2016 17:12:06 +0000 (09:12 -0800)]
Miscellaneous refactorings

* Add comment to the maxlen structure entry about the meaning of maxlen == -1
* Factor-out code common to deque_append(left) and deque_extend(left)
* Factor inner-loop in deque_clear() to use only 1 test per loop instead of 2
* Tighten inner-loops for deque_item() and deque_ass_item() so that the
  compiler can combine the decrement and test into a single step.

9 years agoIssue #26146: marshal.loads() now uses the empty frozenset singleton
Victor Stinner [Sat, 23 Jan 2016 13:15:48 +0000 (14:15 +0100)]
Issue #26146: marshal.loads() now uses the empty frozenset singleton

9 years agoCleanup test_dict
Victor Stinner [Sat, 23 Jan 2016 12:52:05 +0000 (13:52 +0100)]
Cleanup test_dict

* Write one import per line
* Sort imports by name
* Add an empty line: 2 empty lines between code blocks at the module level (PEP 8)

9 years agotest_gc: remove unused imports
Victor Stinner [Sat, 23 Jan 2016 12:29:02 +0000 (13:29 +0100)]
test_gc: remove unused imports

9 years agoIssue #18018: Raise an ImportError if a relative import is attempted
Brett Cannon [Sat, 23 Jan 2016 00:39:02 +0000 (16:39 -0800)]
Issue #18018: Raise an ImportError if a relative import is attempted
with no known parent package.

Previously SystemError was raised if the parent package didn't exist
(e.g., __package__ was set to '').
Thanks to Florent Xicluna and Yongzhi Pan for reporting the issue.

9 years agoIssue #25234: Skip test_eintr.test_open() under OS X to avoid hanging
Brett Cannon [Fri, 22 Jan 2016 23:55:56 +0000 (15:55 -0800)]
Issue #25234: Skip test_eintr.test_open() under OS X to avoid hanging

9 years agowhitespace cleanup
Brett Cannon [Fri, 22 Jan 2016 23:26:56 +0000 (15:26 -0800)]
whitespace cleanup

9 years agoIssue #25791: Warn when __package__ != __spec__.parent.
Brett Cannon [Fri, 22 Jan 2016 23:25:50 +0000 (15:25 -0800)]
Issue #25791: Warn when __package__ != __spec__.parent.

In a previous change, __spec__.parent was prioritized over
__package__. That is a backwards-compatibility break, but we do
eventually want __spec__ to be the ground truth for module details. So
this change reverts the change in semantics and instead raises an
ImportWarning when __package__ != __spec__.parent to give people time
to adjust to using spec objects.

9 years agoMerge from 3.5
Brett Cannon [Fri, 22 Jan 2016 22:05:41 +0000 (14:05 -0800)]
Merge from 3.5

9 years agoFix a typo in a code example
Brett Cannon [Fri, 22 Jan 2016 22:03:27 +0000 (14:03 -0800)]
Fix a typo in a code example

9 years agoMerge 3.5 (i18n doc, issue #25907)
Victor Stinner [Fri, 22 Jan 2016 17:00:31 +0000 (18:00 +0100)]
Merge 3.5 (i18n doc, issue #25907)

9 years agodoc: i18n HTML templates
Victor Stinner [Fri, 22 Jan 2016 17:00:05 +0000 (18:00 +0100)]
doc: i18n HTML templates

Issue #25907: Use {% trans %} tags in HTML templates to ease the translation of
the documentation. The tag comes from Jinja templating system, used by Sphinx.

Patch written by Julien Palard.

9 years agoNull merge 3.5 (change already applied to default)
Victor Stinner [Fri, 22 Jan 2016 14:59:02 +0000 (15:59 +0100)]
Null merge 3.5 (change already applied to default)

9 years agoIssue #25876: Fix also test_set() of test_gdb when -E command line is used
Victor Stinner [Fri, 22 Jan 2016 14:04:27 +0000 (15:04 +0100)]
Issue #25876: Fix also test_set() of test_gdb when -E command line is used

9 years agoIssue #25876: test_gdb: use subprocess._args_from_interpreter_flags() to test
Victor Stinner [Fri, 22 Jan 2016 13:16:47 +0000 (14:16 +0100)]
Issue #25876: test_gdb: use subprocess._args_from_interpreter_flags() to test
Python with more options.