Larry Hastings [Mon, 10 Feb 2014 06:05:19 +0000 (22:05 -0800)]
Issue #20517: Functions in the os module that accept two filenames
now register both filenames in the exception on failure.
This required adding new C API functions allowing OSError exceptions
to reference two filenames instead of one.
Eli Bendersky [Sun, 9 Feb 2014 14:55:58 +0000 (06:55 -0800)]
More complete documentation of event loops and policies.
Documented the AbstractEventLoopPolicy interface explicitly and explained the
relation between the global loop & policy access functions. Added an initial
section that explains the connections in general terms. Documented missing XXX
methods.
Larry Hastings [Sun, 9 Feb 2014 06:15:29 +0000 (22:15 -0800)]
Issue #20530: Argument Clinic's signature format has been revised again.
The new syntax is highly human readable while still preventing false
positives. The syntax also extends Python syntax to denote "self" and
positional-only parameters, allowing inspect.Signature objects to be
totally accurate for all supported builtins in Python 3.4.
R David Murray [Sat, 8 Feb 2014 22:54:56 +0000 (17:54 -0500)]
#14983: always add a line end after a MIME boundary marker.
This is more RFC compliant (see issue) and fixes a problem with
signature verifiers rejecting the part when signed. There is some
amount of backward compatibility concern here since it changes
the output, but the RFC issue coupled with fixing the problem
with signature verifiers seems worth the small risk of breaking
code that depends on the current incorrect output.
Antoine Pitrou [Sat, 8 Feb 2014 22:03:56 +0000 (23:03 +0100)]
Issue #20540: Fix a performance regression (vs. Python 3.2) when layering a multiprocessing Connection over a TCP socket.
For small payloads, Nagle's algorithm would introduce idle delays before the entire transmission of a message.
Antoine Pitrou [Sat, 8 Feb 2014 22:05:52 +0000 (23:05 +0100)]
Issue #20540: Fix a performance regression (vs. Python 3.2) when layering a multiprocessing Connection over a TCP socket.
For small payloads, Nagle's algorithm would introduce idle delays before the entire transmission of a message.
R David Murray [Sat, 8 Feb 2014 18:12:00 +0000 (13:12 -0500)]
#16983: Apply postel's law to encoded words inside quoted strings.
This applies only to the new parser. The old parser decodes encoded words
inside quoted strings already, although it gets the whitespace wrong
when it does so.
This version of the patch only handles the most common case (a single encoded
word surrounded by quotes), but I haven't seen any other variations of this in
the wild yet, so its good enough for now.
R David Murray [Sat, 8 Feb 2014 16:48:20 +0000 (11:48 -0500)]
#19772: Do not mutate message when downcoding to 7bit.
This is a bit of an ugly hack because of the way generator pieces together the
output message. The deepcopys aren't too expensive, though, because we know it
is only called on messages that are not multiparts, and the payload (the thing
that could be large) is an immutable object.
Test and preliminary work on patch by Vajrasky Kok.
Nick Coghlan [Sat, 8 Feb 2014 09:44:16 +0000 (19:44 +1000)]
Issue #20478: avoid special casing Counter in statistics
Passing Counter objects to the Counter constructor is
special cased, going through iter() firsts ensures they
are handled the same way as any other iterable.
(Committing on Steven's behalf as I don't believe his
SSH key is registered yet)
R David Murray [Fri, 7 Feb 2014 18:47:40 +0000 (13:47 -0500)]
#20013: don't raise socket error when selected mailbox deleted.
I'm checking this in without a test because not much of this code
is tested and I don't have time to work up the necessary extensions
to the existing test framework.
The patch itself was tested by the person who reported the bug.
R David Murray [Fri, 7 Feb 2014 18:44:57 +0000 (13:44 -0500)]
#20013: don't raise socket error when selected mailbox deleted.
I'm checking this in without a test because not much of this code
is tested and I don't have time to work up the necessary extensions
to the existing test framework.
The patch itself was tested by the person who reported the bug.
Brett Cannon [Thu, 6 Feb 2014 14:22:51 +0000 (09:22 -0500)]
Issue #6386: When executing a script that's a symlink, the directory
where the symlink resolves to is added to sys.path, not the directory
containing the symlink itself.
Thanks to Sanko Resic for an initial attempt at the patch.