]> granicus.if.org Git - python/commitdiff
Issue #20335: bytes constructor now raises TypeError when encoding or errors
authorSerhiy Storchaka <storchaka@gmail.com>
Tue, 2 Dec 2014 07:26:14 +0000 (09:26 +0200)
committerSerhiy Storchaka <storchaka@gmail.com>
Tue, 2 Dec 2014 07:26:14 +0000 (09:26 +0200)
is specified with non-string argument.  Based on patch by Renaud Blanch.

1  2 
Lib/test/test_bytes.py
Misc/NEWS
Objects/bytesobject.c

Simple merge
diff --cc Misc/NEWS
index c88adc0087e8e304c4d6b8513b207c1add516c95,f48a794c3bd2cb98c683a78253ac3e31a38a5e89..2a43e3ab469b28b257140e5f06dd769bc9be8aed
+++ b/Misc/NEWS
@@@ -10,14 -11,9 +10,17 @@@ Release date: TB
  Core and Builtins
  -----------------
  
+ - Issue #20335: bytes constructor now raises TypeError when encoding or errors
+   is specified with non-string argument.  Based on patch by Renaud Blanch.
 +- Issue #22834: If the current working directory ends up being set to a
 +  non-existent directory then import will no longer raise FileNotFoundError.
 +
 +- Issue #22869: Move the interpreter startup & shutdown code to a new
 +  dedicated pylifecycle.c module
 +
 +- Issue #22847: Improve method cache efficiency.
 +
  - Issue #22335: Fix crash when trying to enlarge a bytearray to 0x7fffffff
    bytes on a 32-bit platform.
  
Simple merge