1 .. bpo: 1878 2 .. date: 7111 3 .. nonce: exCmjh 4 .. release date: 20-Aug-2008 5 .. section: Core and Builtins 6 7 Remove Py_TPFLAGS_HAVE_VERSION_TAG from Py_TPFLAGS_DEFAULT when not building 8 the core. This means 3rd party extensions do not automatically benefit from 9 the class attribute cache; they will have to explicitly add 10 Py_TPFLAGS_HAVE_VERSION_TAG to their tp_flags field if they care. This is a 11 backwards compatibility feature; in 3.0, all types will use the cache by 12 default. 13 14 .. 15 16 .. bpo: 0 17 .. date: 7110 18 .. nonce: 7crJgG 19 .. section: Core and Builtins 20 21 Keyword arguments can now follow starred arguments. (``f(a, *args, 22 keyword=23)`` is now valid syntax.) 23 24 .. 25 26 .. bpo: 0 27 .. date: 7109 28 .. nonce: OfzhCP 29 .. section: Core and Builtins 30 31 ctypes function pointers that are COM methods have a boolean True value 32 again. 33 34 .. 35 36 .. bpo: 3139 37 .. date: 7108 38 .. nonce: j4FT95 39 .. section: Core and Builtins 40 41 Make buffer-interface thread-safe wrt. PyArg_ParseTuple, by denying s# to 42 parse objects that have a releasebuffer procedure, and introducing s*. 43 44 .. 45 46 .. bpo: 3537 47 .. date: 7107 48 .. nonce: Jd1RRZ 49 .. section: Core and Builtins 50 51 Fix an assertion failure when an empty but presized dict object was stored 52 in the freelist. 53 54 .. 55 56 .. bpo: 1481296 57 .. date: 7106 58 .. nonce: 9MXKTf 59 .. section: Core and Builtins 60 61 Make long(float('nan')) and int(float('nan')) raise ValueError consistently 62 across platforms. 63 64 .. 65 66 .. bpo: 3479 67 .. date: 7105 68 .. nonce: 2x4rkT 69 .. section: Core and Builtins 70 71 On platforms where sizeof(int) is smaller than sizeof(long) (64bit Unix, for 72 example), unichr() would truncate its argument and return u'\x00' for 73 unichr(2**32). Now it properly raises an OverflowError. 74 75 .. 76 77 .. bpo: 0 78 .. date: 7104 79 .. nonce: dpio6h 80 .. section: Core and Builtins 81 82 Apply security patches from Apple. 83 84 .. 85 86 .. bpo: 2542 87 .. date: 7103 88 .. nonce: OGrPLh 89 .. section: Core and Builtins 90 91 Now that issubclass() may call arbitrary code, ensure that 92 PyErr_ExceptionMatches returns 0 when an exception occurs there. 93 94 .. 95 96 .. bpo: 1819 97 .. date: 7102 98 .. nonce: LzrD36 99 .. section: Core and Builtins 100 101 function calls with several named parameters are now on average 35% faster 102 (as measured by pybench). 103 104 .. 105 106 .. bpo: 2378 107 .. date: 7101 108 .. nonce: jnJN2_ 109 .. section: Core and Builtins 110 111 An unexpected UnboundLocalError or NameError could appear when the python 112 debugger steps into a class statement: the free variables (local variables 113 defined in an outer scope) would be deleted from the outer scope. 114 115 .. 116 117 .. bpo: 2620 118 .. date: 7100 119 .. nonce: g7NRZZ 120 .. section: Core and Builtins 121 122 Overflow checking when allocating or reallocating memory was not always 123 being done properly in some python types and extension modules. 124 PyMem_MALLOC, PyMem_REALLOC, PyMem_NEW and PyMem_RESIZE have all been 125 updated to perform better checks and places in the code that would 126 previously leak memory on the error path when such an allocation failed have 127 been fixed. 128 129 .. 130 131 .. bpo: 3612 132 .. date: 7099 133 .. nonce: RX3nFS 134 .. section: Library 135 136 Added some missing basic types in ctypes.wintypes. 137 138 .. 139 140 .. bpo: 0 141 .. date: 7098 142 .. nonce: 6arfb- 143 .. section: Library 144 145 The methods ``is_in_tuple()``, ``is_vararg()``, and ``is_keywordarg()`` of 146 symtable.Symbol have been deprecated for removal in 3.0 and the next 147 release. 148 149 .. 150 151 .. bpo: 2234 152 .. date: 7097 153 .. nonce: ZY7qAp 154 .. section: Library 155 156 distutils failed for some versions of the cygwin compiler. The version 157 reported by these tools does not necessarily follow the python version 158 numbering scheme, so the module is less strict when parsing it. 159 160 .. 161 162 .. bpo: 2235 163 .. date: 7096 164 .. nonce: lZ4uDf 165 .. section: Library 166 167 Added Py3k warnings for types which will become unhashable under the 168 stricter __hash__ inheritance rules in 3.0. Several types which did not meet 169 the rules for hash invariants and were already unhashable in 3.0 have now 170 been explicitly flagged as unhashable in 2.6 as well (collections.Mapping, 171 collections.Set, unittest.TestSuite, xml.dom.minidom.NamedNodeMap, 172 numbers.Number, UserList.UserList) 173 174 .. 175 176 .. bpo: 0 177 .. date: 7095 178 .. nonce: njv0Yv 179 .. section: Library 180 181 Update __all__ for cookielib, csv, os, urllib2, and weakref to include 182 things imported into the module but exposed as part of the module's API. 183 184 .. 185 186 .. bpo: 0 187 .. date: 7094 188 .. nonce: IOULx3 189 .. section: Library 190 191 Remove an unneeded import of abc.ABCMeta from 'inspect'. 192 193 .. 194 195 .. bpo: 0 196 .. date: 7093 197 .. nonce: ui1bpi 198 .. section: Library 199 200 Remove unneeded imports of 'sys' and 'warnings' from 'io'. 201 202 .. 203 204 .. bpo: 0 205 .. date: 7092 206 .. nonce: 5UlHtd 207 .. section: Library 208 209 Remove unneeded imports of 'warnings' from shelve, filecmp, and 210 dummy_thread. 211 212 .. 213 214 .. bpo: 3575 215 .. date: 7091 216 .. nonce: f0B44V 217 .. section: Library 218 219 Incremental decoder's decode function now takes bytearray by using 's*' 220 instead of 't#'. 221 222 .. 223 224 .. bpo: 2222 225 .. date: 7090 226 .. nonce: 76LS-7 227 .. section: Library 228 229 Fixed reference leak when occurred os.rename() fails unicode conversion on 230 2nd parameter. (windows only) 231 232 .. 233 234 .. bpo: 2464 235 .. date: 7089 236 .. nonce: Hm7gBN 237 .. section: Library 238 239 urllib2 now supports a malformation in the URL received in a redirect. 240 241 .. 242 243 .. bpo: 0 244 .. date: 7088 245 .. nonce: 1-8Grp 246 .. section: Library 247 248 Silence the DeprecationWarning raised when importing mimetools in 249 BaseHTTPServer, cgi (and rfc822), httplib. 250 251 .. 252 253 .. bpo: 2776 254 .. date: 7087 255 .. nonce: pcfDP0 256 .. section: Library 257 258 fixed small issue when handling a URL with double slash after a 302 response 259 in the case of not going through a proxy. 260 261 .. 262 263 .. bpo: 2676 264 .. date: 7086 265 .. nonce: muz1Bh 266 .. section: Library 267 268 in the email package, content-type parsing was hanging on pathological input 269 because of quadratic or exponential behaviour of a regular expression. 270 271 .. 272 273 .. bpo: 3476 274 .. date: 7085 275 .. nonce: Gdp5Hg 276 .. section: Library 277 278 binary buffered reading through the new "io" library is now thread-safe. 279 280 .. 281 282 .. bpo: 0 283 .. date: 7084 284 .. nonce: 4jao1V 285 .. section: Library 286 287 Silence the DeprecationWarning of rfc822 when it is imported by mimetools 288 since mimetools itself is deprecated. Because modules are cached, all 289 subsequent imports of rfc822 will not raise a visible DeprecationWarning. 290 291 .. 292 293 .. bpo: 3134 294 .. date: 7083 295 .. nonce: sGPHeo 296 .. section: Library 297 298 shutil referenced undefined WindowsError symbol. 299 300 .. 301 302 .. bpo: 1342811 303 .. date: 7082 304 .. nonce: Mf5TLp 305 .. section: Library 306 307 Fix leak in Tkinter.Menu.delete. Commands associated to menu entries were 308 not deleted. 309 310 .. 311 312 .. bpo: 0 313 .. date: 7081 314 .. nonce: XIC5LX 315 .. section: Library 316 317 Copied the implementation of reduce() to _functools.reduce() to have a 318 version that did not raise a DeprecationWarning under -3. 319 320 .. 321 322 .. bpo: 3205 323 .. date: 7080 324 .. nonce: RcrD2G 325 .. section: Library 326 327 When iterating over a BZ2File fails allocating memory, raise a MemoryError 328 rather than silently stop the iteration. 329 330 .. 331 332 .. bpo: 3487 333 .. date: 7079 334 .. nonce: LoL0Xp 335 .. section: Library 336 337 sre "bytecode" validator. Passing invalid "re-bytecode" to _sre.compile() 338 will now be rejected. This should not affect anybody since the re.compile() 339 function never generates invalid re-bytecode. 340 341 .. 342 343 .. bpo: 3436 344 .. date: 7078 345 .. nonce: H10Gz5 346 .. section: Library 347 348 Make csv.DictReader's fieldnames attribute a property so that upon first 349 access it can be automatically initialized from the csv file if it wasn't 350 initialized during instantiation. 351 352 .. 353 354 .. bpo: 2338 355 .. date: 7077 356 .. nonce: jB97v8 357 .. section: Library 358 359 Create imp.reload() to help with transitioning to Python 3.0 as the reload() 360 built-in has been removed. 361 362 .. 363 364 .. bpo: 0 365 .. date: 7076 366 .. nonce: YAmZW- 367 .. section: Library 368 369 Changed code in the following modules/packages to remove warnings raised 370 while running under the ``-3`` flag: aifc, asynchat, asyncore, bdb, bsddb, 371 ConfigParser, cookielib, csv, difflib, distutils, DocXMLRPCServer, email, 372 filecmp, fileinput, inspect, logging, modulefinder, pdb, pickle, profile, 373 pstats, pydoc, re, rlcompleter, SimpleXMLRPCServer, shelve, socket, 374 subprocess, sqlite3, tarfile, Tkinter, test.test_support, textwrap, 375 threading, tokenize, traceback, urlparse, wsgiref, xml, xmlrpclib. 376 377 .. 378 379 .. bpo: 3039 380 .. date: 7075 381 .. nonce: 6106lp 382 .. section: Library 383 384 Fix tarfile.TarFileCompat.writestr() which always raised an AttributeError. 385 386 .. 387 388 .. bpo: 2523 389 .. date: 7074 390 .. nonce: F9osM5 391 .. section: Library 392 393 Fix quadratic behaviour when read()ing a binary file without asking for a 394 specific length. This problem only affected files opened using the new "io" 395 module, not the built-in open() function. 396 397 .. 398 399 .. bpo: 3449 400 .. date: 7073 401 .. nonce: HIJRJS 402 .. section: Library 403 404 Update decimal module to use most recent specification (v. 1.68) and tests 405 (v. 2.58) from IBM. 406 407 .. 408 409 .. bpo: 3437 410 .. date: 7072 411 .. nonce: mFS0ML 412 .. section: Library 413 414 Bug fix in robotparser parsing of Allow: lines. 415 416 .. 417 418 .. bpo: 1592 419 .. date: 7071 420 .. nonce: zq1SOI 421 .. section: Library 422 423 Improve error reporting when operations are attempted on a closed shelf. 424 425 .. 426 427 .. bpo: 0 428 .. date: 7070 429 .. nonce: q6AI_C 430 .. section: Library 431 432 Deprecate the "ast" parser function aliases. 433 434 .. 435 436 .. bpo: 3120 437 .. date: 7069 438 .. nonce: x-kAFj 439 .. section: Library 440 441 On 64-bit Windows the subprocess module was truncating handles. 442 443 .. 444 445 .. bpo: 3303 446 .. date: 7068 447 .. nonce: MGj8zT 448 .. section: Library 449 450 Fix a crash in locale.strcoll() when calling it with invalid arguments. 451 452 .. 453 454 .. bpo: 3302 455 .. date: 7067 456 .. nonce: qnZ5Ic 457 .. section: Library 458 459 Fix several crashes when calling locale's gettext functions with None 460 arguments. 461 462 .. 463 464 .. bpo: 3389 465 .. date: 7066 466 .. nonce: Dhf3EA 467 .. section: Library 468 469 Allow resolving dotted names for handlers in logging configuration files. 470 471 .. 472 473 .. bpo: 0 474 .. date: 7065 475 .. nonce: wtYP5i 476 .. section: Library 477 478 Deprecate the sunaudio module for removal in Python 3.0. 479 480 .. 481 482 .. bpo: 3394 483 .. date: 7064 484 .. nonce: PDdapW 485 .. section: Library 486 487 zipfile.writestr sets external attributes when passed a file name rather 488 than a ZipInfo instance, so files are extracted with mode 0600 rather than 489 000 under Unix. 490 491 .. 492 493 .. bpo: 1857 494 .. date: 7063 495 .. nonce: VLu5_h 496 .. section: Library 497 498 subprocess.Popen.poll gained an additional _deadstate keyword argument in 499 python 2.5, this broke code that subclassed Popen to include its own poll 500 method. Fixed my moving _deadstate to an _internal_poll method. 501 502 .. 503 504 .. bpo: 0 505 .. date: 7062 506 .. nonce: y_hE4z 507 .. section: Build 508 509 Generate the PatternGrammar pickle during "make install". 510 511 .. 512 513 .. bpo: 2235 514 .. date: 7061 515 .. nonce: BMunQV 516 .. section: Documentation 517 518 the C API function PyObject_HashNotImplemented and its interaction with the 519 tp_hash slot (added in 2.6b2) are now documented 520 521 .. 522 523 .. bpo: 643841 524 .. date: 7060 525 .. nonce: Dc77Ec 526 .. section: Documentation 527 528 The language reference now provides more detailed coverage of the lookup 529 process for special methods. The disclaimers regarding lack of coverage of 530 new-style classes have also been removed, since the coverage is now fairly 531 reasonable. 532