1.. bpo: 8271 2.. date: 8078 3.. nonce: HKwc-i 4.. release date: 2010-06-05 5.. section: Core and Builtins 6 7during the decoding of an invalid UTF-8 byte sequence, only the start byte 8and the continuation byte(s) are now considered invalid, instead of the 9number of bytes specified by the start byte. E.g.: 10'\xf1\x80AB'.decode('utf-8', 'replace') now returns u'\ufffdAB' and replaces 11with U+FFFD only the start byte ('\xf1') and the continuation byte ('\x80') 12even if '\xf1' is the start byte of a 4-bytes sequence. Previous versions 13returned a single u'\ufffd'. 14 15.. 16 17.. bpo: 8627 18.. date: 8077 19.. nonce: l2l6Zs 20.. section: Core and Builtins 21 22Remove bogus "Overriding __cmp__ blocks inheritance of __hash__ in 3.x" 23warning. Also fix "XXX undetected error" that arises from the "Overriding 24__eq__ blocks inheritance ..." warning when turned into an exception: in 25this case the exception simply gets ignored. 26 27.. 28 29.. bpo: 8748 30.. date: 8076 31.. nonce: bKymOB 32.. section: Core and Builtins 33 34Fix two issues with comparisons between complex and integer objects. (1) 35The comparison could incorrectly return True in some cases (2**53+1 == 36complex(2**53) == 2**53), breaking transivity of equality. (2) The 37comparison raised an OverflowError for large integers, leading to 38unpredictable exceptions when combining integers and complex objects in sets 39or dicts. 40 41.. 42 43.. bpo: 5211 44.. date: 8075 45.. nonce: BNwm54 46.. section: Core and Builtins 47 48Implicit coercion for the complex type is now completely removed. (Coercion 49for arithmetic operations was already removed in 2.7 alpha 4, but coercion 50for rich comparisons was accidentally left in.) 51 52.. 53 54.. bpo: 3798 55.. date: 8074 56.. nonce: L9n27k 57.. section: Core and Builtins 58 59Write sys.exit() message to sys.stderr to use stderr encoding and error 60handler, instead of writing to the C stderr file in utf-8 61 62.. 63 64.. bpo: 7902 65.. date: 8073 66.. nonce: K75Ezw 67.. section: Core and Builtins 68 69When using explicit relative import syntax, don't try implicit relative 70import semantics. 71 72.. 73 74.. bpo: 7079 75.. date: 8072 76.. nonce: wEGBdB 77.. section: Core and Builtins 78 79Fix a possible crash when closing a file object while using it from another 80thread. Patch by Daniel Stutzbach. 81 82.. 83 84.. bpo: 8868 85.. date: 8071 86.. nonce: rg3J-W 87.. section: Core and Builtins 88 89Fix that ensures that python scripts have access to the Window Server again 90in a framework build on MacOSX 10.5 or earlier. 91 92.. 93 94.. bpo: 5753 95.. date: 8070 96.. nonce: 205374 97.. section: C API 98 99A new C API function, :cfunc:`PySys_SetArgvEx`, allows embedders of the 100interpreter to set sys.argv without also modifying sys.path. This helps fix 101`CVE-2008-5983 102<http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2008-5983>`_. 103 104.. 105 106.. bpo: 8302 107.. date: 8069 108.. nonce: U5tZ_l 109.. section: Library 110 111SkipTest in unittest.TestCase.setUpClass or setUpModule is now reported as a 112skip rather than an error. 113 114.. 115 116.. bpo: 8351 117.. date: 8068 118.. nonce: 8I5oO- 119.. section: Library 120 121Excessively large diffs due to unittest.TestCase.assertSequenceEqual are no 122longer included in failure reports. 123 124.. 125 126.. bpo: 8899 127.. date: 8067 128.. nonce: Q6oIpy 129.. section: Library 130 131time.struct_time now has class and attribute docstrings. 132 133.. 134 135.. bpo: 4487 136.. date: 8066 137.. nonce: WdV86e 138.. section: Library 139 140email now accepts as charset aliases all codec aliases accepted by the 141codecs module. 142 143.. 144 145.. bpo: 6470 146.. date: 8065 147.. nonce: eVTlgU 148.. section: Library 149 150Drop UNC prefix in FixTk. 151 152.. 153 154.. bpo: 5610 155.. date: 8064 156.. nonce: 3x0O2c 157.. section: Library 158 159feedparser no longer eats extra characters at the end of a body part if the 160body part ends with a \r\n. 161 162.. 163 164.. bpo: 8833 165.. date: 8063 166.. nonce: R9JBZA 167.. section: Library 168 169tarfile created hard link entries with a size field != 0 by mistake. 170 171.. 172 173.. bpo: 1368247 174.. date: 8062 175.. nonce: OVD5zb 176.. section: Library 177 178set_charset (and therefore MIMEText) now automatically encodes a unicode 179_payload to the output_charset. 180 181.. 182 183.. bpo: 7150 184.. date: 8061 185.. nonce: kBTznJ 186.. section: Library 187 188Raise OverflowError if the result of adding or subtracting timedelta from 189date or datetime falls outside of the MINYEAR:MAXYEAR range. 190 191.. 192 193.. bpo: 6662 194.. date: 8060 195.. nonce: jpO1QX 196.. section: Library 197 198Fix parsing of malformatted charref (&#bad;), patch written by Fredrik Håård 199 200.. 201 202.. bpo: 8016 203.. date: 8059 204.. nonce: vAmdrz 205.. section: Library 206 207Add the CP858 codec. 208 209.. 210 211.. bpo: 3924 212.. date: 8058 213.. nonce: -W1f1B 214.. section: Library 215 216Ignore cookies with invalid "version" field in cookielib. 217 218.. 219 220.. bpo: 6268 221.. date: 8057 222.. nonce: fQgJxL 223.. section: Library 224 225Fix seek() method of codecs.open(), don't read or write the BOM twice after 226seek(0). Fix also reset() method of codecs, UTF-16, UTF-32 and StreamWriter 227classes. 228 229.. 230 231.. bpo: 5640 232.. date: 8056 233.. nonce: dpc6TZ 234.. section: Library 235 236Fix Shift-JIS incremental encoder for error handlers different than 237'strict'. 238 239.. 240 241.. bpo: 8782 242.. date: 8055 243.. nonce: asLuOV 244.. section: Library 245 246Add a trailing newline in linecache.updatecache to the last line of files 247without one. 248 249.. 250 251.. bpo: 8729 252.. date: 8054 253.. nonce: Nq_Uhf 254.. section: Library 255 256Return NotImplemented from ``collections.Mapping.__eq__()`` when comparing 257to a non-mapping. 258 259.. 260 261.. bpo: 8759 262.. date: 8053 263.. nonce: 0yDlu7 264.. section: Library 265 266Fix user paths in sysconfig for posix and os2 schemes. 267 268.. 269 270.. bpo: 1285086 271.. date: 8052 272.. nonce: U8BtXR 273.. section: Library 274 275Speed up ``urllib.quote()`` and urllib.unquote for simple cases. 276 277.. 278 279.. bpo: 8688 280.. date: 8051 281.. nonce: gUJqmI 282.. section: Library 283 284Distutils now recalculates MANIFEST every time. 285 286.. 287 288.. bpo: 5099 289.. date: 8050 290.. nonce: kmjFaU 291.. section: Library 292 293The ``__del__()`` method of ``subprocess.Popen`` (and the methods it calls) 294referenced global objects, causing errors to pop up during interpreter 295shutdown. 296 297.. 298 299.. bpo: 7384 300.. date: 8049 301.. nonce: E16zrc 302.. section: Library 303 304If the system readline library is linked against ncurses, the curses module 305must be linked against ncurses as well. Otherwise it is not safe to load 306both the readline and curses modules in an application. 307 308.. 309 310.. bpo: 2810 311.. date: 8048 312.. nonce: FSt0Y0 313.. section: Library 314 315Fix cases where the Windows registry API returns ERROR_MORE_DATA, requiring 316a re-try in order to get the complete result. 317 318.. 319 320.. bpo: 8674 321.. date: 8047 322.. nonce: Q2kfWX 323.. section: Library 324 325Fixed a number of incorrect or undefined-behaviour-inducing overflow checks 326in the ``audioop`` module. 327 328.. 329 330.. bpo: 8889 331.. date: 8046 332.. nonce: 9IoVzA 333.. section: Tests 334 335test_support.transient_internet rewritten so that the new checks also work 336on FreeBSD, which lacks EAI_NODATA. 337 338.. 339 340.. bpo: 8835 341.. date: 8045 342.. nonce: FJzJvJ 343.. section: Tests 344 345test_support.transient_internet() catches gaierror(EAI_NONAME) and 346gaierror(EAI_NODATA) 347 348.. 349 350.. bpo: 7449 351.. date: 8044 352.. nonce: LeKyd_ 353.. section: Tests 354 355Skip test_socketserver if threading support is disabled 356 357.. 358 359.. bpo: 0 360.. date: 8043 361.. nonce: b_na1a 362.. section: Tests 363 364On darwin, ``test_site`` assumed that a framework build was being used, 365leading to a failure where four directories were expected for site-packages 366instead of two in a non-framework build. 367 368.. 369 370.. bpo: 0 371.. date: 8042 372.. nonce: g-v7fs 373.. section: Build 374 375Display installer warning that Windows 2000 won't be supported in future 376releases. 377 378.. 379 380.. bpo: 1759169 381.. date: 8041 382.. nonce: NW035m 383.. section: Build 384 385Drop _XOPEN_SOURCE on Solaris, define it for multiprocessing only. (See 386also: bpo-8864) 387 388.. 389 390.. bpo: 5464 391.. date: 8040 392.. nonce: R1pj9Y 393.. section: Tools/Demos 394 395Implement plural forms in msgfmt.py. 396