1.. bpo: 31975
2.. date: 2018-01-05-20-54-27
3.. nonce: AmftlU
4.. release date: 2018-01-08
5.. section: Core and Builtins
6
7The default warning filter list now starts with a
8"default::DeprecationWarning:__main__" entry, so deprecation warnings are
9once again shown by default in single-file scripts and at the interactive
10prompt.
11
12..
13
14.. bpo: 32226
15.. date: 2018-01-04-15-06-15
16.. nonce: 7cAvRG
17.. section: Core and Builtins
18
19``__class_getitem__`` is now an automatic class method.
20
21..
22
23.. bpo: 32399
24.. date: 2017-12-22-13-38-17
25.. nonce: wlH12z
26.. section: Core and Builtins
27
28Add AIX uuid library support for RFC4122 using uuid_create() in libc.a
29
30..
31
32.. bpo: 32390
33.. date: 2017-12-22-13-28-07
34.. nonce: QPj083
35.. section: Core and Builtins
36
37Fix the compilation failure on AIX after the f_fsid field has been added to
38the object returned by os.statvfs() (issue #32143). Original patch by
39Michael Felt.
40
41..
42
43.. bpo: 32379
44.. date: 2017-12-19-21-14-41
45.. nonce: B7mOmI
46.. section: Core and Builtins
47
48Make MRO computation faster when a class inherits from a single base.
49
50..
51
52.. bpo: 32259
53.. date: 2017-12-16-14-30-21
54.. nonce: GoOJiX
55.. section: Core and Builtins
56
57The error message of a TypeError raised when unpack non-iterable is now more
58specific.
59
60..
61
62.. bpo: 27169
63.. date: 2017-12-15-11-50-06
64.. nonce: VO84fQ
65.. section: Core and Builtins
66
67The ``__debug__`` constant is now optimized out at compile time. This fixes
68also bpo-22091.
69
70..
71
72.. bpo: 32329
73.. date: 2017-12-15-00-13-04
74.. nonce: q47IN2
75.. section: Core and Builtins
76
77The :option:`-R` option now turns on hash randomization when the
78:envvar:`PYTHONHASHSEED` environment variable is set to ``0``. Previously,
79the option was ignored. Moreover, ``sys.flags.hash_randomization`` is now
80properly set to 0 when hash randomization is turned off by
81``PYTHONHASHSEED=0``.
82
83..
84
85.. bpo: 30416
86.. date: 2017-12-14-11-48-19
87.. nonce: hlHo_9
88.. section: Core and Builtins
89
90The optimizer is now protected from spending much time doing complex
91calculations and consuming much memory for creating large constants in
92constant folding. Increased limits for constants that can be produced in
93constant folding.
94
95..
96
97.. bpo: 32282
98.. date: 2017-12-12-14-02-28
99.. nonce: xFVMTn
100.. section: Core and Builtins
101
102Fix an unnecessary ifdef in the include of VersionHelpers.h in socketmodule
103on Windows.
104
105..
106
107.. bpo: 30579
108.. date: 2017-12-11-01-52-42
109.. nonce: X6cEzf
110.. section: Core and Builtins
111
112Implement TracebackType.__new__ to allow Python-level creation of traceback
113objects, and make TracebackType.tb_next mutable.
114
115..
116
117.. bpo: 32260
118.. date: 2017-12-09-11-03-51
119.. nonce: 1DAO-p
120.. section: Core and Builtins
121
122Don't byte swap the input keys to the SipHash algorithm on big-endian
123platforms. This should ensure siphash gives consistent results across
124platforms.
125
126..
127
128.. bpo: 31506
129.. date: 2017-12-07-23-44-29
130.. nonce: j1U2fU
131.. section: Core and Builtins
132
133Improve the error message logic for object.__new__ and object.__init__.
134Patch by Sanyam Khurana.
135
136..
137
138.. bpo: 20361
139.. date: 2017-12-07-17-22-30
140.. nonce: zQUmbi
141.. section: Core and Builtins
142
143``-b`` and ``-bb`` now inject ``'default::BytesWarning'`` and
144``error::BytesWarning`` entries into ``sys.warnoptions``, ensuring that they
145take precedence over any other warning filters configured via the ``-W``
146option or the ``PYTHONWARNINGS`` environment variable.
147
148..
149
150.. bpo: 32230
151.. date: 2017-12-06-20-18-34
152.. nonce: PgGQaB
153.. section: Core and Builtins
154
155`-X dev` now injects a ``'default'`` entry into sys.warnoptions, ensuring
156that it behaves identically to actually passing ``-Wdefault`` at the command
157line.
158
159..
160
161.. bpo: 29240
162.. date: 2017-12-05-23-10-58
163.. nonce: qpJP5l
164.. section: Core and Builtins
165
166Add a new UTF-8 mode: implementation of the :pep:`540`.
167
168..
169
170.. bpo: 32226
171.. date: 2017-12-05-21-42-58
172.. nonce: G8fqb6
173.. section: Core and Builtins
174
175:pep:`560`: Add support for ``__mro_entries__`` and ``__class_getitem__``. Implemented
176by Ivan Levkivskyi.
177
178..
179
180.. bpo: 32225
181.. date: 2017-12-05-21-33-47
182.. nonce: ucKjvw
183.. section: Core and Builtins
184
185:pep:`562`: Add support for module ``__getattr__`` and ``__dir__``. Implemented
186by Ivan Levkivskyi.
187
188..
189
190.. bpo: 31901
191.. date: 2017-11-28-15-04-14
192.. nonce: mDeCLK
193.. section: Core and Builtins
194
195The `atexit` module now has its callback stored per interpreter.
196
197..
198
199.. bpo: 31650
200.. date: 2017-11-26-14-38-44
201.. nonce: JWf_Im
202.. section: Core and Builtins
203
204Implement :pep:`552` (Deterministic pycs). Python now supports invalidating
205bytecode cache files bashed on a source content hash rather than source
206last-modified time.
207
208..
209
210.. bpo: 29469
211.. date: 2017-07-26-00-20-15
212.. nonce: potmyI
213.. section: Core and Builtins
214
215Move constant folding from bytecode layer to AST layer. Original patch by
216Eugene Toder.
217
218..
219
220.. bpo: 32506
221.. date: 2018-01-07-11-32-42
222.. nonce: MaT-zU
223.. section: Library
224
225Now that dict is defined as keeping insertion order, drop OrderedDict and
226just use plain dict.
227
228..
229
230.. bpo: 32279
231.. date: 2018-01-06-16-50-11
232.. nonce: 1xOpU8
233.. section: Library
234
235Add params to dataclasses.make_dataclasses(): init, repr, eq, order, hash,
236and frozen.  Pass them through to dataclass().
237
238..
239
240.. bpo: 32278
241.. date: 2018-01-06-15-15-34
242.. nonce: bGnGc0
243.. section: Library
244
245Make type information optional on dataclasses.make_dataclass(). If omitted,
246the string 'typing.Any' is used.
247
248..
249
250.. bpo: 32499
251.. date: 2018-01-06-10-54-16
252.. nonce: koyY-4
253.. section: Library
254
255Add dataclasses.is_dataclass(obj), which returns True if obj is a dataclass
256or an instance of one.
257
258..
259
260.. bpo: 32468
261.. date: 2017-12-31-20-32-58
262.. nonce: YBs__0
263.. section: Library
264
265Improve frame repr() to mention filename, code name and current line number.
266
267..
268
269.. bpo: 23749
270.. date: 2017-12-29-00-44-42
271.. nonce: QL1Cxd
272.. section: Library
273
274asyncio: Implement loop.start_tls()
275
276..
277
278.. bpo: 32441
279.. date: 2017-12-28-21-30-40
280.. nonce: LqlboJ
281.. section: Library
282
283Return the new file descriptor (i.e., the second argument) from ``os.dup2``.
284Previously, ``None`` was always returned.
285
286..
287
288.. bpo: 32422
289.. date: 2017-12-25-20-22-47
290.. nonce: 5H3Wq2
291.. section: Library
292
293``functools.lru_cache`` uses less memory (3 words for each cached key) and
294takes about 1/3 time for cyclic GC.
295
296..
297
298.. bpo: 31721
299.. date: 2017-12-25-11-09-46
300.. nonce: 5gM972
301.. section: Library
302
303Prevent Python crash from happening when Future._log_traceback is set to
304True manually.  Now it can only be set to False, or a ValueError is raised.
305
306..
307
308.. bpo: 32415
309.. date: 2017-12-23-12-45-00
310.. nonce: YufXTU
311.. section: Library
312
313asyncio: Add Task.get_loop() and Future.get_loop()
314
315..
316
317.. bpo: 26133
318.. date: 2017-12-21-11-08-42
319.. nonce: mt81QV
320.. section: Library
321
322Don't unsubscribe signals in asyncio UNIX event loop on interpreter
323shutdown.
324
325..
326
327.. bpo: 32363
328.. date: 2017-12-19-00-37-28
329.. nonce: YTeGU0
330.. section: Library
331
332Make asyncio.Task.set_exception() and set_result() raise
333NotImplementedError. Task._step() and Future.__await__() raise proper
334exceptions when they are in an invalid state, instead of raising an
335AssertionError.
336
337..
338
339.. bpo: 32357
340.. date: 2017-12-18-00-36-41
341.. nonce: t1F3sn
342.. section: Library
343
344Optimize asyncio.iscoroutine() and loop.create_task() for non-native
345coroutines (e.g. async/await compiled with Cython).
346
347'loop.create_task(python_coroutine)' used to be 20% faster than
348'loop.create_task(cython_coroutine)'.  Now, the latter is as fast.
349
350..
351
352.. bpo: 32356
353.. date: 2017-12-17-22-50-51
354.. nonce: roZJpA
355.. section: Library
356
357asyncio.transport.resume_reading() and pause_reading() are now idempotent.
358New transport.is_reading() method is added.
359
360..
361
362.. bpo: 32355
363.. date: 2017-12-17-21-42-24
364.. nonce: tbaTWA
365.. section: Library
366
367Optimize asyncio.gather(); now up to 15% faster.
368
369..
370
371.. bpo: 32351
372.. date: 2017-12-17-14-23-23
373.. nonce: 95fh2K
374.. section: Library
375
376Use fastpath in asyncio.sleep if delay<0 (2x boost)
377
378..
379
380.. bpo: 32348
381.. date: 2017-12-16-18-50-57
382.. nonce: 5j__he
383.. section: Library
384
385Optimize asyncio.Future schedule/add/remove callback.  The optimization
386shows 3-6% performance improvements of async/await code.
387
388..
389
390.. bpo: 32331
391.. date: 2017-12-15-23-48-43
392.. nonce: fIg1Uc
393.. section: Library
394
395Fix socket.settimeout() and socket.setblocking() to keep socket.type as is.
396Fix socket.socket() constructor to reset any bit flags applied to socket's
397type.  This change only affects OSes that have SOCK_NONBLOCK and/or
398SOCK_CLOEXEC.
399
400..
401
402.. bpo: 32248
403.. date: 2017-12-15-15-34-12
404.. nonce: zmO8G2
405.. section: Library
406
407Add :class:`importlib.abc.ResourceReader` as an ABC for loaders to provide a
408unified API for reading resources contained within packages.  Also add
409:mod:`importlib.resources` as the port of ``importlib_resources``.
410
411..
412
413.. bpo: 32311
414.. date: 2017-12-14-17-28-54
415.. nonce: DL5Ytn
416.. section: Library
417
418Implement asyncio.create_task(coro) shortcut
419
420..
421
422.. bpo: 32327
423.. date: 2017-12-14-16-00-25
424.. nonce: bbkSxA
425.. section: Library
426
427Convert asyncio functions that were documented as coroutines to coroutines.
428Affected functions: loop.sock_sendall, loop.sock_recv, loop.sock_accept,
429loop.getaddrinfo, loop.getnameinfo.
430
431..
432
433.. bpo: 32323
434.. date: 2017-12-14-10-10-10
435.. nonce: ideco
436.. section: Library
437
438:func:`urllib.parse.urlsplit()` does not convert zone-id (scope) to lower
439case for scoped IPv6 addresses in hostnames now.
440
441..
442
443.. bpo: 32302
444.. date: 2017-12-13-22-38-08
445.. nonce: othtTr
446.. section: Library
447
448Fix bdist_wininst of distutils for CRT v142: it binary compatible with CRT
449v140.
450
451..
452
453.. bpo: 29711
454.. date: 2017-12-13-22-10-36
455.. nonce: hJjghA
456.. section: Library
457
458Fix ``stop_serving`` in asyncio proactor loop kill all listening servers
459
460..
461
462.. bpo: 32308
463.. date: 2017-12-13-20-31-30
464.. nonce: CUbsb2
465.. section: Library
466
467:func:`re.sub()` now replaces empty matches adjacent to a previous non-empty
468match.
469
470..
471
472.. bpo: 29970
473.. date: 2017-12-13-19-02-38
474.. nonce: uxVOpk
475.. section: Library
476
477Abort asyncio SSLProtocol connection if handshake not complete within 10s
478
479..
480
481.. bpo: 32314
482.. date: 2017-12-13-16-47-38
483.. nonce: W4_U2j
484.. section: Library
485
486Implement asyncio.run().
487
488..
489
490.. bpo: 17852
491.. date: 2017-12-13-00-00-37
492.. nonce: Q8BP8N
493.. section: Library
494
495Revert incorrect fix based on misunderstanding of _Py_PyAtExit() semantics.
496
497..
498
499.. bpo: 32296
500.. date: 2017-12-12-18-01-01
501.. nonce: bwscHz
502.. section: Library
503
504Implement asyncio._get_running_loop() and get_event_loop() in C. This makes
505them 4x faster.
506
507..
508
509.. bpo: 32250
510.. date: 2017-12-12-16-58-20
511.. nonce: UljTa0
512.. section: Library
513
514Implement ``asyncio.current_task()`` and ``asyncio.all_tasks()``. Add
515helpers intended to be used by alternative task implementations:
516``asyncio._register_task``, ``asyncio._enter_task``, ``asyncio._leave_task``
517and ``asyncio._unregister_task``. Deprecate ``asyncio.Task.current_task()``
518and ``asyncio.Task.all_tasks()``.
519
520..
521
522.. bpo: 32255
523.. date: 2017-12-12-07-29-06
524.. nonce: 2bfNmM
525.. section: Library
526
527A single empty field is now always quoted when written into a CSV file. This
528allows to distinguish an empty row from a row consisting of a single empty
529field. Patch by Licht Takeuchi.
530
531..
532
533.. bpo: 32277
534.. date: 2017-12-11-09-53-14
535.. nonce: jkKiVC
536.. section: Library
537
538Raise ``NotImplementedError`` instead of ``SystemError`` on platforms where
539``chmod(..., follow_symlinks=False)`` is not supported.  Patch by Anthony
540Sottile.
541
542..
543
544.. bpo: 30050
545.. date: 2017-12-10-23-44-56
546.. nonce: 4SZ3lY
547.. section: Library
548
549New argument warn_on_full_buffer to signal.set_wakeup_fd lets you control
550whether Python prints a warning on stderr when the wakeup fd buffer
551overflows.
552
553..
554
555.. bpo: 29137
556.. date: 2017-12-10-21-19-14
557.. nonce: CFcON1
558.. section: Library
559
560The ``fpectl`` library has been removed. It was never enabled by default,
561never worked correctly on x86-64, and it changed the Python ABI in ways that
562caused unexpected breakage of C extensions.
563
564..
565
566.. bpo: 32273
567.. date: 2017-12-10-19-14-55
568.. nonce: 5KKlCv
569.. section: Library
570
571Move asyncio.test_utils to test.test_asyncio.
572
573..
574
575.. bpo: 32272
576.. date: 2017-12-10-18-59-13
577.. nonce: Mu84Am
578.. section: Library
579
580Remove asyncio.async() function.
581
582..
583
584.. bpo: 32269
585.. date: 2017-12-10-12-30-13
586.. nonce: Q85pKj
587.. section: Library
588
589Add asyncio.get_running_loop() function.
590
591..
592
593.. bpo: 32265
594.. date: 2017-12-10-00-57-51
595.. nonce: kELtTE
596.. section: Library
597
598All class and static methods of builtin types now are correctly classified
599by inspect.classify_class_attrs() and grouped in pydoc ouput. Added
600types.ClassMethodDescriptorType for unbound class methods of builtin types.
601
602..
603
604.. bpo: 32253
605.. date: 2017-12-09-11-30-35
606.. nonce: TQHSYF
607.. section: Library
608
609Deprecate ``yield from lock``, ``await lock``, ``with (yield from lock)``
610and ``with await lock`` for asyncio synchronization primitives.
611
612..
613
614.. bpo: 22589
615.. date: 2017-12-08-15-09-41
616.. nonce: 8ouqI6
617.. section: Library
618
619Changed MIME type of .bmp from 'image/x-ms-bmp' to 'image/bmp'
620
621..
622
623.. bpo: 32193
624.. date: 2017-12-08-11-02-26
625.. nonce: NJe_TQ
626.. section: Library
627
628Convert asyncio to use *async/await* syntax. Old styled ``yield from`` is
629still supported too.
630
631..
632
633.. bpo: 32206
634.. date: 2017-12-07-13-14-40
635.. nonce: obm4OM
636.. section: Library
637
638Add support to run modules with pdb
639
640..
641
642.. bpo: 32227
643.. date: 2017-12-05-13-25-15
644.. nonce: 3vnWFS
645.. section: Library
646
647``functools.singledispatch`` now supports registering implementations using
648type annotations.
649
650..
651
652.. bpo: 15873
653.. date: 2017-12-04-17-41-40
654.. nonce: -T4TRK
655.. section: Library
656
657Added new alternate constructors :meth:`datetime.datetime.fromisoformat`,
658:meth:`datetime.time.fromisoformat` and :meth:`datetime.date.fromisoformat`
659as the inverse operation of each classes's respective ``isoformat`` methods.
660
661..
662
663.. bpo: 32199
664.. date: 2017-12-04-12-23-26
665.. nonce: nGof4v
666.. section: Library
667
668The getnode() ip getter now uses 'ip link' instead of 'ip link list'.
669
670..
671
672.. bpo: 32143
673.. date: 2017-11-26-17-28-26
674.. nonce: o7YdXL
675.. section: Library
676
677os.statvfs() includes the f_fsid field from statvfs(2)
678
679..
680
681.. bpo: 26439
682.. date: 2017-11-24-08-35-43
683.. nonce: IC45_f
684.. section: Library
685
686Fix ctypes.util.find_library() for AIX by implementing
687ctypes._aix.find_library() Patch by: Michael Felt
688
689..
690
691.. bpo: 31993
692.. date: 2017-11-10-00-05-08
693.. nonce: -OMNg8
694.. section: Library
695
696The pickler now uses less memory when serializing large bytes and str
697objects into a file.  Pickles created with protocol 4 will require less
698memory for unpickling large bytes and str objects.
699
700..
701
702.. bpo: 27456
703.. date: 2017-11-02-11-57-41
704.. nonce: snzyTC
705.. section: Library
706
707Ensure TCP_NODELAY is set on Linux. Tests by Victor Stinner.
708
709..
710
711.. bpo: 31778
712.. date: 2017-10-18-17-29-30
713.. nonce: B6vAkP
714.. section: Library
715
716ast.literal_eval() is now more strict. Addition and subtraction of arbitrary
717numbers no longer allowed.
718
719..
720
721.. bpo: 31802
722.. date: 2017-10-17-14-52-14
723.. nonce: sYj2Zv
724.. section: Library
725
726Importing native path module (``posixpath``, ``ntpath``) now works even if
727the ``os`` module still is not imported.
728
729..
730
731.. bpo: 30241
732.. date: 2017-10-10-18-56-46
733.. nonce: F_go20
734.. section: Library
735
736Add contextlib.AbstractAsyncContextManager. Patch by Jelle Zijlstra.
737
738..
739
740.. bpo: 31699
741.. date: 2017-10-05-11-06-32
742.. nonce: MF47Y6
743.. section: Library
744
745Fix deadlocks in :class:`concurrent.futures.ProcessPoolExecutor` when task
746arguments or results cause pickling or unpickling errors. This should make
747sure that calls to the :class:`ProcessPoolExecutor` API always eventually
748return.
749
750..
751
752.. bpo: 15216
753.. date: 2017-09-16-02-56-33
754.. nonce: lqXCTT
755.. section: Library
756
757``TextIOWrapper.reconfigure()`` supports changing *encoding*, *errors*, and
758*newline*.
759
760..
761
762.. bpo: 32418
763.. date: 2017-12-24-17-29-37
764.. nonce: eZe-ID
765.. section: Documentation
766
767Add get_loop() method to Server and AbstractServer classes.
768
769..
770
771.. bpo: 32252
772.. date: 2017-12-11-13-31-33
773.. nonce: YnFw7J
774.. section: Tests
775
776Fix faulthandler_suppress_crash_report() used to prevent core dump files
777when testing crashes. getrlimit() returns zero on success.
778
779..
780
781.. bpo: 32002
782.. date: 2017-11-11-16-35-18
783.. nonce: itDxIo
784.. section: Tests
785
786Adjust C locale coercion testing for the empty locale and POSIX locale cases
787to more readily adjust to platform dependent behaviour.
788
789..
790
791.. bpo: 19764
792.. date: 2017-08-18-18-00-24
793.. nonce: ODpc9y
794.. section: Windows
795
796Implement support for `subprocess.Popen(close_fds=True)` on Windows. Patch
797by Segev Finer.
798
799..
800
801.. bpo: 24960
802.. date: 2017-12-22-09-25-51
803.. nonce: TGdAgO
804.. section: Tools/Demos
805
8062to3 and lib2to3 can now read pickled grammar files using pkgutil.get_data()
807rather than probing the filesystem. This lets 2to3 and lib2to3 work when run
808from a zipfile.
809
810..
811
812.. bpo: 32030
813.. date: 2017-12-20-23-22-32
814.. nonce: d1dcwh
815.. section: C API
816
817Py_Initialize() doesn't reset the memory allocators to default if the
818``PYTHONMALLOC`` environment variable is not set.
819
820..
821
822.. bpo: 29084
823.. date: 2017-12-16-09-59-35
824.. nonce: ZGJ-LJ
825.. section: C API
826
827Undocumented C API for OrderedDict has been excluded from the limited C API.
828It was added by mistake and actually never worked in the limited C API.
829
830..
831
832.. bpo: 32264
833.. date: 2017-12-12-23-09-46
834.. nonce: ahRlOI
835.. section: C API
836
837Moved the pygetopt.h header into internal/, since it has no public APIs.
838
839..
840
841.. bpo: 32241
842.. date: 2017-12-07-15-58-15
843.. nonce: LbyQt6
844.. section: C API
845
846:c:func:`Py_SetProgramName` and :c:func:`Py_SetPythonHome` now take the
847``const wchar *`` arguments instead of ``wchar *``.
848