# -*- coding: utf-8 -*-
-# Autogenerated by Sphinx on Fri Nov 5 19:03:45 2021
+# Autogenerated by Sphinx on Wed Dec 8 22:23:59 2021
topics = {'assert': 'The "assert" statement\n'
'**********************\n'
'\n'
' "A.__dict__[\'x\'].__get__(None, A)".\n'
'\n'
'Super Binding\n'
- ' If "a" is an instance of "super", then the binding '
- '"super(B,\n'
- ' obj).m()" searches "obj.__class__.__mro__" for the '
- 'base class "A"\n'
- ' immediately preceding "B" and then invokes the '
- 'descriptor with the\n'
- ' call: "A.__dict__[\'m\'].__get__(obj, '
- 'obj.__class__)".\n'
+ ' A dotted lookup such as "super(A, a).x" searches\n'
+ ' "a.__class__.__mro__" for a base class "B" following '
+ '"A" and then\n'
+ ' returns "B.__dict__[\'x\'].__get__(a, A)". If not a '
+ 'descriptor, "x"\n'
+ ' is returned unchanged.\n'
'\n'
'For instance bindings, the precedence of descriptor '
'invocation depends\n'
'can be\n'
'overridden by instances.\n'
'\n'
- 'Python methods (including "staticmethod()" and '
- '"classmethod()") are\n'
- 'implemented as non-data descriptors. Accordingly, '
- 'instances can\n'
- 'redefine and override methods. This allows individual '
- 'instances to\n'
- 'acquire behaviors that differ from other instances of '
- 'the same class.\n'
+ 'Python methods (including those decorated with '
+ '"@staticmethod" and\n'
+ '"@classmethod") are implemented as non-data '
+ 'descriptors. Accordingly,\n'
+ 'instances can redefine and override methods. This '
+ 'allows individual\n'
+ 'instances to acquire behaviors that differ from other '
+ 'instances of the\n'
+ 'same class.\n'
'\n'
'The "property()" function is implemented as a data '
'descriptor.\n'
'\n'
'*__slots__* allow us to explicitly declare data members '
'(like\n'
- 'properties) and deny the creation of *__dict__* and '
+ 'properties) and deny the creation of "__dict__" and '
'*__weakref__*\n'
'(unless explicitly declared in *__slots__* or available '
'in a parent.)\n'
'\n'
- 'The space saved over using *__dict__* can be '
+ 'The space saved over using "__dict__" can be '
'significant. Attribute\n'
'lookup speed can be significantly improved as well.\n'
'\n'
'*__slots__*\n'
' reserves space for the declared variables and '
'prevents the\n'
- ' automatic creation of *__dict__* and *__weakref__* '
+ ' automatic creation of "__dict__" and *__weakref__* '
'for each\n'
' instance.\n'
'\n'
'--------------------------\n'
'\n'
'* When inheriting from a class without *__slots__*, the '
- '*__dict__* and\n'
+ '"__dict__" and\n'
' *__weakref__* attribute of the instances will always '
'be accessible.\n'
'\n'
- '* Without a *__dict__* variable, instances cannot be '
+ '* Without a "__dict__" variable, instances cannot be '
'assigned new\n'
' variables not listed in the *__slots__* definition. '
'Attempts to\n'
'\n'
'* Without a *__weakref__* variable for each instance, '
'classes defining\n'
- ' *__slots__* do not support weak references to its '
- 'instances. If weak\n'
- ' reference support is needed, then add '
+ ' *__slots__* do not support "weak references" to its '
+ 'instances. If\n'
+ ' weak reference support is needed, then add '
'"\'__weakref__\'" to the\n'
' sequence of strings in the *__slots__* declaration.\n'
'\n'
'* *__slots__* are implemented at the class level by '
'creating\n'
- ' descriptors (Implementing Descriptors) for each '
- 'variable name. As a\n'
- ' result, class attributes cannot be used to set default '
- 'values for\n'
- ' instance variables defined by *__slots__*; otherwise, '
- 'the class\n'
- ' attribute would overwrite the descriptor assignment.\n'
+ ' descriptors for each variable name. As a result, '
+ 'class attributes\n'
+ ' cannot be used to set default values for instance '
+ 'variables defined\n'
+ ' by *__slots__*; otherwise, the class attribute would '
+ 'overwrite the\n'
+ ' descriptor assignment.\n'
'\n'
'* The action of a *__slots__* declaration is not limited '
'to the class\n'
' where it is defined. *__slots__* declared in parents '
'are available\n'
' in child classes. However, child subclasses will get a '
- '*__dict__*\n'
+ '"__dict__"\n'
' and *__weakref__* unless they also define *__slots__* '
'(which should\n'
' only contain names of any *additional* slots).\n'
'may be\n'
' assigned to the values corresponding to each key.\n'
'\n'
- '* *__class__* assignment works only if both classes have '
+ '* "__class__" assignment works only if both classes have '
'the same\n'
' *__slots__*.\n'
'\n'
'violations\n'
' raise "TypeError".\n'
'\n'
- '* If an iterator is used for *__slots__* then a '
- 'descriptor is created\n'
- ' for each of the iterator’s values. However, the '
- '*__slots__*\n'
+ '* If an *iterator* is used for *__slots__* then a '
+ '*descriptor* is\n'
+ ' created for each of the iterator’s values. However, '
+ 'the *__slots__*\n'
' attribute will be an empty iterator.\n',
'attribute-references': 'Attribute references\n'
'********************\n'
'parameter name, the first slot is used, and so on). If the slot '
'is\n'
'already filled, a "TypeError" exception is raised. Otherwise, the\n'
- 'value of the argument is placed in the slot, filling it (even if '
- 'the\n'
- 'expression is "None", it fills the slot). When all arguments have\n'
- 'been processed, the slots that are still unfilled are filled with '
- 'the\n'
- 'corresponding default value from the function definition. '
- '(Default\n'
- 'values are calculated, once, when the function is defined; thus, a\n'
- 'mutable object such as a list or dictionary used as default value '
- 'will\n'
- 'be shared by all calls that don’t specify an argument value for '
- 'the\n'
- 'corresponding slot; this should usually be avoided.) If there are '
- 'any\n'
- 'unfilled slots for which no default value is specified, a '
- '"TypeError"\n'
- 'exception is raised. Otherwise, the list of filled slots is used '
- 'as\n'
- 'the argument list for the call.\n'
+ 'argument is placed in the slot, filling it (even if the expression '
+ 'is\n'
+ '"None", it fills the slot). When all arguments have been '
+ 'processed,\n'
+ 'the slots that are still unfilled are filled with the '
+ 'corresponding\n'
+ 'default value from the function definition. (Default values are\n'
+ 'calculated, once, when the function is defined; thus, a mutable '
+ 'object\n'
+ 'such as a list or dictionary used as default value will be shared '
+ 'by\n'
+ 'all calls that don’t specify an argument value for the '
+ 'corresponding\n'
+ 'slot; this should usually be avoided.) If there are any unfilled\n'
+ 'slots for which no default value is specified, a "TypeError" '
+ 'exception\n'
+ 'is raised. Otherwise, the list of filled slots is used as the\n'
+ 'argument list for the call.\n'
'\n'
'**CPython implementation detail:** An implementation may provide\n'
'built-in functions whose positional parameters do not have names, '
'syntax\n'
'to be used in the same call, so in practice this confusion does '
'not\n'
- 'arise.\n'
+ 'often arise.\n'
'\n'
'If the syntax "**expression" appears in the function call,\n'
'"expression" must evaluate to a *mapping*, the contents of which '
'binding\n'
'operations.\n'
'\n'
- 'The following constructs bind names: formal parameters to '
- 'functions,\n'
- '"import" statements, class and function definitions (these bind '
- 'the\n'
- 'class or function name in the defining block), and targets that '
- 'are\n'
- 'identifiers if occurring in an assignment, "for" loop header, '
- 'or after\n'
- '"as" in a "with" statement or "except" clause. The "import" '
- 'statement\n'
- 'of the form "from ... import *" binds all names defined in the\n'
- 'imported module, except those beginning with an underscore. '
- 'This form\n'
- 'may only be used at the module level.\n'
+ 'The following constructs bind names:\n'
+ '\n'
+ '* formal parameters to functions,\n'
+ '\n'
+ '* class definitions,\n'
+ '\n'
+ '* function definitions,\n'
+ '\n'
+ '* assignment expressions,\n'
+ '\n'
+ '* targets that are identifiers if occurring in an assignment:\n'
+ '\n'
+ ' * "for" loop header,\n'
+ '\n'
+ ' * after "as" in a "with" statement, "except" clause or in the '
+ 'as-\n'
+ ' pattern in structural pattern matching,\n'
+ '\n'
+ ' * in a capture pattern in structural pattern matching\n'
+ '\n'
+ '* "import" statements.\n'
+ '\n'
+ 'The "import" statement of the form "from ... import *" binds '
+ 'all names\n'
+ 'defined in the imported module, except those beginning with an\n'
+ 'underscore. This form may only be used at the module level.\n'
'\n'
'A target occurring in a "del" statement is also considered '
'bound for\n'
'*Names* refer to objects. Names are introduced by name binding\n'
'operations.\n'
'\n'
- 'The following constructs bind names: formal parameters to '
- 'functions,\n'
- '"import" statements, class and function definitions (these bind '
- 'the\n'
- 'class or function name in the defining block), and targets that '
- 'are\n'
- 'identifiers if occurring in an assignment, "for" loop header, or '
- 'after\n'
- '"as" in a "with" statement or "except" clause. The "import" '
- 'statement\n'
- 'of the form "from ... import *" binds all names defined in the\n'
- 'imported module, except those beginning with an underscore. This '
- 'form\n'
- 'may only be used at the module level.\n'
+ 'The following constructs bind names:\n'
+ '\n'
+ '* formal parameters to functions,\n'
+ '\n'
+ '* class definitions,\n'
+ '\n'
+ '* function definitions,\n'
+ '\n'
+ '* assignment expressions,\n'
+ '\n'
+ '* targets that are identifiers if occurring in an assignment:\n'
+ '\n'
+ ' * "for" loop header,\n'
+ '\n'
+ ' * after "as" in a "with" statement, "except" clause or in the '
+ 'as-\n'
+ ' pattern in structural pattern matching,\n'
+ '\n'
+ ' * in a capture pattern in structural pattern matching\n'
+ '\n'
+ '* "import" statements.\n'
+ '\n'
+ 'The "import" statement of the form "from ... import *" binds all '
+ 'names\n'
+ 'defined in the imported module, except those beginning with an\n'
+ 'underscore. This form may only be used at the module level.\n'
'\n'
'A target occurring in a "del" statement is also considered bound '
'for\n'
'\n'
'New in version 3.3: The "__suppress_context__" attribute to '
'suppress\n'
- 'automatic display of the exception context.\n',
+ 'automatic display of the exception context.\n'
+ '\n'
+ 'Changed in version 3.11: If the traceback of the active exception '
+ 'is\n'
+ 'modified in an "except" clause, a subsequent "raise" statement re-\n'
+ 'raises the exception with the modified traceback. Previously, the\n'
+ 'exception was re-raised with the traceback it had when it was '
+ 'caught.\n',
'return': 'The "return" statement\n'
'**********************\n'
'\n'
'\n'
'The following methods can be defined to implement '
'container objects.\n'
- 'Containers usually are sequences (such as lists or tuples) '
- 'or mappings\n'
- '(like dictionaries), but can represent other containers as '
- 'well. The\n'
- 'first set of methods is used either to emulate a sequence '
- 'or to\n'
- 'emulate a mapping; the difference is that for a sequence, '
- 'the\n'
- 'allowable keys should be the integers *k* for which "0 <= '
- 'k < N" where\n'
- '*N* is the length of the sequence, or slice objects, which '
- 'define a\n'
- 'range of items. It is also recommended that mappings '
- 'provide the\n'
- 'methods "keys()", "values()", "items()", "get()", '
- '"clear()",\n'
- '"setdefault()", "pop()", "popitem()", "copy()", and '
- '"update()"\n'
- 'behaving similar to those for Python’s standard dictionary '
+ 'Containers usually are *sequences* (such as "lists" or '
+ '"tuples") or\n'
+ '*mappings* (like "dictionaries"), but can represent other '
+ 'containers\n'
+ 'as well. The first set of methods is used either to '
+ 'emulate a\n'
+ 'sequence or to emulate a mapping; the difference is that '
+ 'for a\n'
+ 'sequence, the allowable keys should be the integers *k* '
+ 'for which "0\n'
+ '<= k < N" where *N* is the length of the sequence, or '
+ '"slice" objects,\n'
+ 'which define a range of items. It is also recommended '
+ 'that mappings\n'
+ 'provide the methods "keys()", "values()", "items()", '
+ '"get()",\n'
+ '"clear()", "setdefault()", "pop()", "popitem()", "copy()", '
+ 'and\n'
+ '"update()" behaving similar to those for Python’s '
+ 'standard\n'
+ '"dictionary" objects. The "collections.abc" module '
+ 'provides a\n'
+ '"MutableMapping" *abstract base class* to help create '
+ 'those methods\n'
+ 'from a base set of "__getitem__()", "__setitem__()", '
+ '"__delitem__()",\n'
+ 'and "keys()". Mutable sequences should provide methods '
+ '"append()",\n'
+ '"count()", "index()", "extend()", "insert()", "pop()", '
+ '"remove()",\n'
+ '"reverse()" and "sort()", like Python standard "list" '
'objects.\n'
- 'The "collections.abc" module provides a "MutableMapping" '
- 'abstract base\n'
- 'class to help create those methods from a base set of '
- '"__getitem__()",\n'
- '"__setitem__()", "__delitem__()", and "keys()". Mutable '
- 'sequences\n'
- 'should provide methods "append()", "count()", "index()", '
- '"extend()",\n'
- '"insert()", "pop()", "remove()", "reverse()" and "sort()", '
- 'like Python\n'
- 'standard list objects. Finally, sequence types should '
- 'implement\n'
- 'addition (meaning concatenation) and multiplication '
+ 'Finally, sequence types should implement addition '
'(meaning\n'
- 'repetition) by defining the methods "__add__()", '
- '"__radd__()",\n'
- '"__iadd__()", "__mul__()", "__rmul__()" and "__imul__()" '
- 'described\n'
- 'below; they should not define other numerical operators. '
+ 'concatenation) and multiplication (meaning repetition) by '
+ 'defining the\n'
+ 'methods "__add__()", "__radd__()", "__iadd__()", '
+ '"__mul__()",\n'
+ '"__rmul__()" and "__imul__()" described below; they should '
+ 'not define\n'
+ 'other numerical operators. It is recommended that both '
+ 'mappings and\n'
+ 'sequences implement the "__contains__()" method to allow '
+ 'efficient use\n'
+ 'of the "in" operator; for mappings, "in" should search the '
+ 'mapping’s\n'
+ 'keys; for sequences, it should search through the values. '
'It is\n'
- 'recommended that both mappings and sequences implement '
+ 'further recommended that both mappings and sequences '
+ 'implement the\n'
+ '"__iter__()" method to allow efficient iteration through '
'the\n'
- '"__contains__()" method to allow efficient use of the "in" '
- 'operator;\n'
- 'for mappings, "in" should search the mapping’s keys; for '
- 'sequences, it\n'
- 'should search through the values. It is further '
- 'recommended that both\n'
- 'mappings and sequences implement the "__iter__()" method '
- 'to allow\n'
- 'efficient iteration through the container; for mappings, '
- '"__iter__()"\n'
- 'should iterate through the object’s keys; for sequences, '
- 'it should\n'
- 'iterate through the values.\n'
+ 'container; for mappings, "__iter__()" should iterate '
+ 'through the\n'
+ 'object’s keys; for sequences, it should iterate through '
+ 'the values.\n'
'\n'
'object.__len__(self)\n'
'\n'
'object.__getitem__(self, key)\n'
'\n'
' Called to implement evaluation of "self[key]". For '
- 'sequence types,\n'
- ' the accepted keys should be integers and slice '
- 'objects. Note that\n'
- ' the special interpretation of negative indexes (if the '
- 'class wishes\n'
- ' to emulate a sequence type) is up to the '
- '"__getitem__()" method. If\n'
- ' *key* is of an inappropriate type, "TypeError" may be '
- 'raised; if of\n'
- ' a value outside the set of indexes for the sequence '
- '(after any\n'
- ' special interpretation of negative values), '
- '"IndexError" should be\n'
- ' raised. For mapping types, if *key* is missing (not in '
+ '*sequence*\n'
+ ' types, the accepted keys should be integers and slice '
+ 'objects.\n'
+ ' Note that the special interpretation of negative '
+ 'indexes (if the\n'
+ ' class wishes to emulate a *sequence* type) is up to '
'the\n'
- ' container), "KeyError" should be raised.\n'
+ ' "__getitem__()" method. If *key* is of an inappropriate '
+ 'type,\n'
+ ' "TypeError" may be raised; if of a value outside the '
+ 'set of indexes\n'
+ ' for the sequence (after any special interpretation of '
+ 'negative\n'
+ ' values), "IndexError" should be raised. For *mapping* '
+ 'types, if\n'
+ ' *key* is missing (not in the container), "KeyError" '
+ 'should be\n'
+ ' raised.\n'
'\n'
' Note:\n'
'\n'
'of the\n'
' sequence.\n'
'\n'
+ ' Note:\n'
+ '\n'
+ ' When subscripting a *class*, the special class '
+ 'method\n'
+ ' "__class_getitem__()" may be called instead of '
+ '"__getitem__()".\n'
+ ' See __class_getitem__ versus __getitem__ for more '
+ 'details.\n'
+ '\n'
'object.__setitem__(self, key, value)\n'
'\n'
' Called to implement assignment to "self[key]". Same '
'\n'
'object.__iter__(self)\n'
'\n'
- ' This method is called when an iterator is required for '
- 'a container.\n'
- ' This method should return a new iterator object that '
- 'can iterate\n'
- ' over all the objects in the container. For mappings, '
- 'it should\n'
- ' iterate over the keys of the container.\n'
- '\n'
- ' Iterator objects also need to implement this method; '
- 'they are\n'
- ' required to return themselves. For more information on '
- 'iterator\n'
- ' objects, see Iterator Types.\n'
+ ' This method is called when an *iterator* is required '
+ 'for a\n'
+ ' container. This method should return a new iterator '
+ 'object that can\n'
+ ' iterate over all the objects in the container. For '
+ 'mappings, it\n'
+ ' should iterate over the keys of the container.\n'
'\n'
'object.__reversed__(self)\n'
'\n'
' "A.__dict__[\'x\'].__get__(None, A)".\n'
'\n'
'Super Binding\n'
- ' If "a" is an instance of "super", then the binding '
- '"super(B,\n'
- ' obj).m()" searches "obj.__class__.__mro__" for the base '
- 'class "A"\n'
- ' immediately preceding "B" and then invokes the descriptor '
- 'with the\n'
- ' call: "A.__dict__[\'m\'].__get__(obj, obj.__class__)".\n'
+ ' A dotted lookup such as "super(A, a).x" searches\n'
+ ' "a.__class__.__mro__" for a base class "B" following "A" '
+ 'and then\n'
+ ' returns "B.__dict__[\'x\'].__get__(a, A)". If not a '
+ 'descriptor, "x"\n'
+ ' is returned unchanged.\n'
'\n'
'For instance bindings, the precedence of descriptor '
'invocation depends\n'
'be\n'
'overridden by instances.\n'
'\n'
- 'Python methods (including "staticmethod()" and '
- '"classmethod()") are\n'
- 'implemented as non-data descriptors. Accordingly, instances '
- 'can\n'
- 'redefine and override methods. This allows individual '
- 'instances to\n'
- 'acquire behaviors that differ from other instances of the '
+ 'Python methods (including those decorated with '
+ '"@staticmethod" and\n'
+ '"@classmethod") are implemented as non-data descriptors. '
+ 'Accordingly,\n'
+ 'instances can redefine and override methods. This allows '
+ 'individual\n'
+ 'instances to acquire behaviors that differ from other '
+ 'instances of the\n'
'same class.\n'
'\n'
'The "property()" function is implemented as a data '
'\n'
'*__slots__* allow us to explicitly declare data members '
'(like\n'
- 'properties) and deny the creation of *__dict__* and '
+ 'properties) and deny the creation of "__dict__" and '
'*__weakref__*\n'
'(unless explicitly declared in *__slots__* or available in a '
'parent.)\n'
'\n'
- 'The space saved over using *__dict__* can be significant. '
+ 'The space saved over using "__dict__" can be significant. '
'Attribute\n'
'lookup speed can be significantly improved as well.\n'
'\n'
'*__slots__*\n'
' reserves space for the declared variables and prevents '
'the\n'
- ' automatic creation of *__dict__* and *__weakref__* for '
+ ' automatic creation of "__dict__" and *__weakref__* for '
'each\n'
' instance.\n'
'\n'
'~~~~~~~~~~~~~~~~~~~~~~~~~~\n'
'\n'
'* When inheriting from a class without *__slots__*, the '
- '*__dict__* and\n'
+ '"__dict__" and\n'
' *__weakref__* attribute of the instances will always be '
'accessible.\n'
'\n'
- '* Without a *__dict__* variable, instances cannot be '
+ '* Without a "__dict__" variable, instances cannot be '
'assigned new\n'
' variables not listed in the *__slots__* definition. '
'Attempts to\n'
'\n'
'* Without a *__weakref__* variable for each instance, '
'classes defining\n'
- ' *__slots__* do not support weak references to its '
- 'instances. If weak\n'
- ' reference support is needed, then add "\'__weakref__\'" to '
- 'the\n'
+ ' *__slots__* do not support "weak references" to its '
+ 'instances. If\n'
+ ' weak reference support is needed, then add '
+ '"\'__weakref__\'" to the\n'
' sequence of strings in the *__slots__* declaration.\n'
'\n'
'* *__slots__* are implemented at the class level by '
'creating\n'
- ' descriptors (Implementing Descriptors) for each variable '
- 'name. As a\n'
- ' result, class attributes cannot be used to set default '
- 'values for\n'
- ' instance variables defined by *__slots__*; otherwise, the '
- 'class\n'
- ' attribute would overwrite the descriptor assignment.\n'
+ ' descriptors for each variable name. As a result, class '
+ 'attributes\n'
+ ' cannot be used to set default values for instance '
+ 'variables defined\n'
+ ' by *__slots__*; otherwise, the class attribute would '
+ 'overwrite the\n'
+ ' descriptor assignment.\n'
'\n'
'* The action of a *__slots__* declaration is not limited to '
'the class\n'
' where it is defined. *__slots__* declared in parents are '
'available\n'
' in child classes. However, child subclasses will get a '
- '*__dict__*\n'
+ '"__dict__"\n'
' and *__weakref__* unless they also define *__slots__* '
'(which should\n'
' only contain names of any *additional* slots).\n'
'be\n'
' assigned to the values corresponding to each key.\n'
'\n'
- '* *__class__* assignment works only if both classes have the '
+ '* "__class__" assignment works only if both classes have the '
'same\n'
' *__slots__*.\n'
'\n'
'violations\n'
' raise "TypeError".\n'
'\n'
- '* If an iterator is used for *__slots__* then a descriptor '
- 'is created\n'
- ' for each of the iterator’s values. However, the '
+ '* If an *iterator* is used for *__slots__* then a '
+ '*descriptor* is\n'
+ ' created for each of the iterator’s values. However, the '
'*__slots__*\n'
' attribute will be an empty iterator.\n'
'\n'
'==========================\n'
'\n'
'Whenever a class inherits from another class, '
- '*__init_subclass__* is\n'
+ '"__init_subclass__()" is\n'
'called on that class. This way, it is possible to write '
'classes which\n'
'change the behavior of subclasses. This is closely related '
'come from\n'
'the class definition). The "__prepare__" method should be '
'implemented\n'
- 'as a "classmethod()". The namespace returned by '
- '"__prepare__" is\n'
- 'passed in to "__new__", but when the final class object is '
- 'created the\n'
+ 'as a "classmethod". The namespace returned by "__prepare__" '
+ 'is passed\n'
+ 'in to "__new__", but when the final class object is created '
+ 'the\n'
'namespace is copied into a new "dict".\n'
'\n'
'If the metaclass has no "__prepare__" attribute, then the '
'Emulating generic types\n'
'=======================\n'
'\n'
- 'One can implement the generic class syntax as specified by '
- '**PEP 484**\n'
- '(for example "List[int]") by defining a special method:\n'
+ 'When using *type annotations*, it is often useful to '
+ '*parameterize* a\n'
+ '*generic type* using Python’s square-brackets notation. For '
+ 'example,\n'
+ 'the annotation "list[int]" might be used to signify a "list" '
+ 'in which\n'
+ 'all the elements are of type "int".\n'
+ '\n'
+ 'See also:\n'
+ '\n'
+ ' **PEP 484** - Type Hints\n'
+ ' Introducing Python’s framework for type annotations\n'
+ '\n'
+ ' Generic Alias Types\n'
+ ' Documentation for objects representing parameterized '
+ 'generic\n'
+ ' classes\n'
+ '\n'
+ ' Generics, user-defined generics and "typing.Generic"\n'
+ ' Documentation on how to implement generic classes that '
+ 'can be\n'
+ ' parameterized at runtime and understood by static '
+ 'type-checkers.\n'
+ '\n'
+ 'A class can *generally* only be parameterized if it defines '
+ 'the\n'
+ 'special class method "__class_getitem__()".\n'
'\n'
'classmethod object.__class_getitem__(cls, key)\n'
'\n'
'generic class\n'
' by type arguments found in *key*.\n'
'\n'
- 'This method is looked up on the class object itself, and '
- 'when defined\n'
- 'in the class body, this method is implicitly a class '
- 'method. Note,\n'
- 'this mechanism is primarily reserved for use with static '
- 'type hints,\n'
- 'other usage is discouraged.\n'
+ ' When defined on a class, "__class_getitem__()" is '
+ 'automatically a\n'
+ ' class method. As such, there is no need for it to be '
+ 'decorated with\n'
+ ' "@classmethod" when it is defined.\n'
+ '\n'
+ '\n'
+ 'The purpose of *__class_getitem__*\n'
+ '----------------------------------\n'
+ '\n'
+ 'The purpose of "__class_getitem__()" is to allow runtime\n'
+ 'parameterization of standard-library generic classes in '
+ 'order to more\n'
+ 'easily apply *type hints* to these classes.\n'
+ '\n'
+ 'To implement custom generic classes that can be '
+ 'parameterized at\n'
+ 'runtime and understood by static type-checkers, users should '
+ 'either\n'
+ 'inherit from a standard library class that already '
+ 'implements\n'
+ '"__class_getitem__()", or inherit from "typing.Generic", '
+ 'which has its\n'
+ 'own implementation of "__class_getitem__()".\n'
+ '\n'
+ 'Custom implementations of "__class_getitem__()" on classes '
+ 'defined\n'
+ 'outside of the standard library may not be understood by '
+ 'third-party\n'
+ 'type-checkers such as mypy. Using "__class_getitem__()" on '
+ 'any class\n'
+ 'for purposes other than type hinting is discouraged.\n'
+ '\n'
+ '\n'
+ '*__class_getitem__* versus *__getitem__*\n'
+ '----------------------------------------\n'
+ '\n'
+ 'Usually, the subscription of an object using square brackets '
+ 'will call\n'
+ 'the "__getitem__()" instance method defined on the object’s '
+ 'class.\n'
+ 'However, if the object being subscribed is itself a class, '
+ 'the class\n'
+ 'method "__class_getitem__()" may be called instead.\n'
+ '"__class_getitem__()" should return a GenericAlias object if '
+ 'it is\n'
+ 'properly defined.\n'
+ '\n'
+ 'Presented with the *expression* "obj[x]", the Python '
+ 'interpreter\n'
+ 'follows something like the following process to decide '
+ 'whether\n'
+ '"__getitem__()" or "__class_getitem__()" should be called:\n'
+ '\n'
+ ' from inspect import isclass\n'
+ '\n'
+ ' def subscribe(obj, x):\n'
+ ' """Return the result of the expression \'obj[x]\'"""\n'
+ '\n'
+ ' class_of_obj = type(obj)\n'
+ '\n'
+ ' # If the class of obj defines __getitem__,\n'
+ ' # call class_of_obj.__getitem__(obj, x)\n'
+ " if hasattr(class_of_obj, '__getitem__'):\n"
+ ' return class_of_obj.__getitem__(obj, x)\n'
+ '\n'
+ ' # Else, if obj is a class and defines '
+ '__class_getitem__,\n'
+ ' # call obj.__class_getitem__(x)\n'
+ ' elif isclass(obj) and hasattr(obj, '
+ "'__class_getitem__'):\n"
+ ' return obj.__class_getitem__(x)\n'
+ '\n'
+ ' # Else, raise an exception\n'
+ ' else:\n'
+ ' raise TypeError(\n'
+ ' f"\'{class_of_obj.__name__}\' object is not '
+ 'subscriptable"\n'
+ ' )\n'
+ '\n'
+ 'In Python, all classes are themselves instances of other '
+ 'classes. The\n'
+ 'class of a class is known as that class’s *metaclass*, and '
+ 'most\n'
+ 'classes have the "type" class as their metaclass. "type" '
+ 'does not\n'
+ 'define "__getitem__()", meaning that expressions such as '
+ '"list[int]",\n'
+ '"dict[str, float]" and "tuple[str, bytes]" all result in\n'
+ '"__class_getitem__()" being called:\n'
+ '\n'
+ ' >>> # list has class "type" as its metaclass, like most '
+ 'classes:\n'
+ ' >>> type(list)\n'
+ " <class 'type'>\n"
+ ' >>> type(dict) == type(list) == type(tuple) == type(str) '
+ '== type(bytes)\n'
+ ' True\n'
+ ' >>> # "list[int]" calls "list.__class_getitem__(int)"\n'
+ ' >>> list[int]\n'
+ ' list[int]\n'
+ ' >>> # list.__class_getitem__ returns a GenericAlias '
+ 'object:\n'
+ ' >>> type(list[int])\n'
+ " <class 'types.GenericAlias'>\n"
+ '\n'
+ 'However, if a class has a custom metaclass that defines\n'
+ '"__getitem__()", subscribing the class may result in '
+ 'different\n'
+ 'behaviour. An example of this can be found in the "enum" '
+ 'module:\n'
+ '\n'
+ ' >>> from enum import Enum\n'
+ ' >>> class Menu(Enum):\n'
+ ' ... """A breakfast menu"""\n'
+ " ... SPAM = 'spam'\n"
+ " ... BACON = 'bacon'\n"
+ ' ...\n'
+ ' >>> # Enum classes have a custom metaclass:\n'
+ ' >>> type(Menu)\n'
+ " <class 'enum.EnumMeta'>\n"
+ ' >>> # EnumMeta defines __getitem__,\n'
+ ' >>> # so __class_getitem__ is not called,\n'
+ ' >>> # and the result is not a GenericAlias object:\n'
+ " >>> Menu['SPAM']\n"
+ " <Menu.SPAM: 'spam'>\n"
+ " >>> type(Menu['SPAM'])\n"
+ " <enum 'Menu'>\n"
'\n'
'See also:\n'
'\n'
- ' **PEP 560** - Core support for typing module and generic '
+ ' **PEP 560** - Core Support for typing module and generic '
'types\n'
+ ' Introducing "__class_getitem__()", and outlining when '
+ 'a\n'
+ ' subscription results in "__class_getitem__()" being '
+ 'called\n'
+ ' instead of "__getitem__()"\n'
'\n'
'\n'
'Emulating callable objects\n'
'\n'
'The following methods can be defined to implement container '
'objects.\n'
- 'Containers usually are sequences (such as lists or tuples) '
- 'or mappings\n'
- '(like dictionaries), but can represent other containers as '
- 'well. The\n'
- 'first set of methods is used either to emulate a sequence or '
- 'to\n'
- 'emulate a mapping; the difference is that for a sequence, '
- 'the\n'
- 'allowable keys should be the integers *k* for which "0 <= k '
- '< N" where\n'
- '*N* is the length of the sequence, or slice objects, which '
- 'define a\n'
- 'range of items. It is also recommended that mappings '
- 'provide the\n'
- 'methods "keys()", "values()", "items()", "get()", '
- '"clear()",\n'
- '"setdefault()", "pop()", "popitem()", "copy()", and '
- '"update()"\n'
- 'behaving similar to those for Python’s standard dictionary '
+ 'Containers usually are *sequences* (such as "lists" or '
+ '"tuples") or\n'
+ '*mappings* (like "dictionaries"), but can represent other '
+ 'containers\n'
+ 'as well. The first set of methods is used either to emulate '
+ 'a\n'
+ 'sequence or to emulate a mapping; the difference is that for '
+ 'a\n'
+ 'sequence, the allowable keys should be the integers *k* for '
+ 'which "0\n'
+ '<= k < N" where *N* is the length of the sequence, or '
+ '"slice" objects,\n'
+ 'which define a range of items. It is also recommended that '
+ 'mappings\n'
+ 'provide the methods "keys()", "values()", "items()", '
+ '"get()",\n'
+ '"clear()", "setdefault()", "pop()", "popitem()", "copy()", '
+ 'and\n'
+ '"update()" behaving similar to those for Python’s standard\n'
+ '"dictionary" objects. The "collections.abc" module provides '
+ 'a\n'
+ '"MutableMapping" *abstract base class* to help create those '
+ 'methods\n'
+ 'from a base set of "__getitem__()", "__setitem__()", '
+ '"__delitem__()",\n'
+ 'and "keys()". Mutable sequences should provide methods '
+ '"append()",\n'
+ '"count()", "index()", "extend()", "insert()", "pop()", '
+ '"remove()",\n'
+ '"reverse()" and "sort()", like Python standard "list" '
'objects.\n'
- 'The "collections.abc" module provides a "MutableMapping" '
- 'abstract base\n'
- 'class to help create those methods from a base set of '
- '"__getitem__()",\n'
- '"__setitem__()", "__delitem__()", and "keys()". Mutable '
- 'sequences\n'
- 'should provide methods "append()", "count()", "index()", '
- '"extend()",\n'
- '"insert()", "pop()", "remove()", "reverse()" and "sort()", '
- 'like Python\n'
- 'standard list objects. Finally, sequence types should '
- 'implement\n'
- 'addition (meaning concatenation) and multiplication '
- '(meaning\n'
- 'repetition) by defining the methods "__add__()", '
- '"__radd__()",\n'
- '"__iadd__()", "__mul__()", "__rmul__()" and "__imul__()" '
- 'described\n'
- 'below; they should not define other numerical operators. It '
- 'is\n'
- 'recommended that both mappings and sequences implement the\n'
- '"__contains__()" method to allow efficient use of the "in" '
- 'operator;\n'
- 'for mappings, "in" should search the mapping’s keys; for '
- 'sequences, it\n'
- 'should search through the values. It is further recommended '
- 'that both\n'
- 'mappings and sequences implement the "__iter__()" method to '
- 'allow\n'
- 'efficient iteration through the container; for mappings, '
- '"__iter__()"\n'
- 'should iterate through the object’s keys; for sequences, it '
- 'should\n'
- 'iterate through the values.\n'
+ 'Finally, sequence types should implement addition (meaning\n'
+ 'concatenation) and multiplication (meaning repetition) by '
+ 'defining the\n'
+ 'methods "__add__()", "__radd__()", "__iadd__()", '
+ '"__mul__()",\n'
+ '"__rmul__()" and "__imul__()" described below; they should '
+ 'not define\n'
+ 'other numerical operators. It is recommended that both '
+ 'mappings and\n'
+ 'sequences implement the "__contains__()" method to allow '
+ 'efficient use\n'
+ 'of the "in" operator; for mappings, "in" should search the '
+ 'mapping’s\n'
+ 'keys; for sequences, it should search through the values. '
+ 'It is\n'
+ 'further recommended that both mappings and sequences '
+ 'implement the\n'
+ '"__iter__()" method to allow efficient iteration through '
+ 'the\n'
+ 'container; for mappings, "__iter__()" should iterate through '
+ 'the\n'
+ 'object’s keys; for sequences, it should iterate through the '
+ 'values.\n'
'\n'
'object.__len__(self)\n'
'\n'
'object.__getitem__(self, key)\n'
'\n'
' Called to implement evaluation of "self[key]". For '
- 'sequence types,\n'
- ' the accepted keys should be integers and slice objects. '
- 'Note that\n'
- ' the special interpretation of negative indexes (if the '
- 'class wishes\n'
- ' to emulate a sequence type) is up to the "__getitem__()" '
- 'method. If\n'
- ' *key* is of an inappropriate type, "TypeError" may be '
- 'raised; if of\n'
- ' a value outside the set of indexes for the sequence '
- '(after any\n'
- ' special interpretation of negative values), "IndexError" '
+ '*sequence*\n'
+ ' types, the accepted keys should be integers and slice '
+ 'objects.\n'
+ ' Note that the special interpretation of negative indexes '
+ '(if the\n'
+ ' class wishes to emulate a *sequence* type) is up to the\n'
+ ' "__getitem__()" method. If *key* is of an inappropriate '
+ 'type,\n'
+ ' "TypeError" may be raised; if of a value outside the set '
+ 'of indexes\n'
+ ' for the sequence (after any special interpretation of '
+ 'negative\n'
+ ' values), "IndexError" should be raised. For *mapping* '
+ 'types, if\n'
+ ' *key* is missing (not in the container), "KeyError" '
'should be\n'
- ' raised. For mapping types, if *key* is missing (not in '
- 'the\n'
- ' container), "KeyError" should be raised.\n'
+ ' raised.\n'
'\n'
' Note:\n'
'\n'
'the\n'
' sequence.\n'
'\n'
+ ' Note:\n'
+ '\n'
+ ' When subscripting a *class*, the special class method\n'
+ ' "__class_getitem__()" may be called instead of '
+ '"__getitem__()".\n'
+ ' See __class_getitem__ versus __getitem__ for more '
+ 'details.\n'
+ '\n'
'object.__setitem__(self, key, value)\n'
'\n'
' Called to implement assignment to "self[key]". Same note '
'\n'
'object.__iter__(self)\n'
'\n'
- ' This method is called when an iterator is required for a '
- 'container.\n'
- ' This method should return a new iterator object that can '
- 'iterate\n'
- ' over all the objects in the container. For mappings, it '
- 'should\n'
- ' iterate over the keys of the container.\n'
- '\n'
- ' Iterator objects also need to implement this method; they '
- 'are\n'
- ' required to return themselves. For more information on '
- 'iterator\n'
- ' objects, see Iterator Types.\n'
+ ' This method is called when an *iterator* is required for '
+ 'a\n'
+ ' container. This method should return a new iterator '
+ 'object that can\n'
+ ' iterate over all the objects in the container. For '
+ 'mappings, it\n'
+ ' should iterate over the keys of the container.\n'
'\n'
'object.__reversed__(self)\n'
'\n'
' A function or method which uses the "yield" statement (see\n'
' section The yield statement) is called a *generator '
'function*.\n'
- ' Such a function, when called, always returns an iterator '
- 'object\n'
- ' which can be used to execute the body of the function: '
- 'calling\n'
- ' the iterator’s "iterator.__next__()" method will cause the\n'
- ' function to execute until it provides a value using the '
- '"yield"\n'
- ' statement. When the function executes a "return" statement '
- 'or\n'
- ' falls off the end, a "StopIteration" exception is raised and '
- 'the\n'
- ' iterator will have reached the end of the set of values to '
- 'be\n'
- ' returned.\n'
+ ' Such a function, when called, always returns an *iterator*\n'
+ ' object which can be used to execute the body of the '
+ 'function:\n'
+ ' calling the iterator’s "iterator.__next__()" method will '
+ 'cause\n'
+ ' the function to execute until it provides a value using the\n'
+ ' "yield" statement. When the function executes a "return"\n'
+ ' statement or falls off the end, a "StopIteration" exception '
+ 'is\n'
+ ' raised and the iterator will have reached the end of the set '
+ 'of\n'
+ ' values to be returned.\n'
'\n'
' Coroutine functions\n'
' A function or method which is defined using "async def" is\n'
' which uses the "yield" statement is called a *asynchronous\n'
' generator function*. Such a function, when called, returns '
'an\n'
- ' asynchronous iterator object which can be used in an "async '
- 'for"\n'
- ' statement to execute the body of the function.\n'
+ ' *asynchronous iterator* object which can be used in an '
+ '"async\n'
+ ' for" statement to execute the body of the function.\n'
'\n'
- ' Calling the asynchronous iterator’s "aiterator.__anext__()"\n'
- ' method will return an *awaitable* which when awaited will\n'
- ' execute until it provides a value using the "yield" '
- 'expression.\n'
- ' When the function executes an empty "return" statement or '
- 'falls\n'
- ' off the end, a "StopAsyncIteration" exception is raised and '
+ ' Calling the asynchronous iterator’s "aiterator.__anext__" '
+ 'method\n'
+ ' will return an *awaitable* which when awaited will execute '
+ 'until\n'
+ ' it provides a value using the "yield" expression. When the\n'
+ ' function executes an empty "return" statement or falls off '
'the\n'
+ ' end, a "StopAsyncIteration" exception is raised and the\n'
' asynchronous iterator will have reached the end of the set '
'of\n'
' values to be yielded.\n'
--- /dev/null
+.. bpo: 46009
+.. date: 2021-12-08-11-06-53
+.. nonce: cL8pH0
+.. release date: 2021-12-08
+.. section: Core and Builtins
+
+Restore behavior from 3.9 and earlier when sending non-None to newly started
+generator. In 3.9 this did not affect the state of the generator. In 3.10.0
+and 3.10.1 ``gen_func().send(0)`` is equivalent to
+``gen_func().throw(TypeError(...)`` which exhausts the generator. In 3.10.2
+onward, the behavior has been reverted to that of 3.9.
+
+..
+
+.. bpo: 46004
+.. date: 2021-12-07-11-24-24
+.. nonce: TTEU1p
+.. section: Core and Builtins
+
+Fix the :exc:`SyntaxError` location for errors involving for loops with
+invalid targets. Patch by Pablo Galindo
+
+..
+
+.. bpo: 45711
+.. date: 2021-12-05-17-36-08
+.. nonce: 3TmTSw
+.. section: Core and Builtins
+
+:c:func:`_PyErr_ChainStackItem` no longer normalizes ``exc_info`` (including
+setting the traceback on the exception instance) because ``exc_info`` is
+always normalized.
+
+..
+
+.. bpo: 45607
+.. date: 2021-12-01-15-38-04
+.. nonce: JhuF8b
+.. section: Core and Builtins
+
+The ``__note__`` field was added to :exc:`BaseException`. It is ``None`` by
+default but can be set to a string which is added to the exception's
+traceback.
+
+..
+
+.. bpo: 45947
+.. date: 2021-12-01-14-06-36
+.. nonce: 1XPPm_
+.. section: Core and Builtins
+
+Place pointers to dict and values immediately before GC header. This reduces
+number of dependent memory loads to access either dict or values from 3 to
+1.
+
+..
+
+.. bpo: 45915
+.. date: 2021-11-28-11-25-08
+.. nonce: TSGcLF
+.. section: Core and Builtins
+
+``is_valid_fd`` now uses faster ``fcntl(fd, F_GETFD)`` on Linux, macOS, and
+Windows.
+
+..
+
+.. bpo: 44530
+.. date: 2021-11-26-23-26-25
+.. nonce: EZ0gel
+.. section: Core and Builtins
+
+Reverts a change to the ``code.__new__`` :ref:`audit event <audit-events>`
+from an earlier prerelease.
+
+..
+
+.. bpo: 42268
+.. date: 2021-11-26-22-31-22
+.. nonce: 3wl-09
+.. section: Core and Builtins
+
+Fail the configure step if the selected compiler doesn't support memory
+sanitizer. Patch by Pablo Galindo
+
+..
+
+.. bpo: 45711
+.. date: 2021-11-25-17-51-29
+.. nonce: D2igmz
+.. section: Core and Builtins
+
+The three values of ``exc_info`` are now always consistent with each other.
+In particular, the ``type`` and ``traceback`` fields are now derived from
+the exception instance. This impacts the return values of
+:func:`sys.exc_info` and :c:func:`PyErr_GetExcInfo()` if the exception
+instance is modified while the exception is handled, as well as
+:c:func:`PyErr_SetExcInfo()`, which now ignores the ``type`` and
+``traceback`` arguments provided to it.
+
+..
+
+.. bpo: 45727
+.. date: 2021-11-24-18-24-49
+.. nonce: _xVbbo
+.. section: Core and Builtins
+
+Refine the custom syntax error that suggests that a comma may be missing to
+trigger only when the expressions are detected between parentheses or
+brackets. Patch by Pablo Galindo
+
+..
+
+.. bpo: 45885
+.. date: 2021-11-23-21-01-56
+.. nonce: 3IxeCX
+.. section: Core and Builtins
+
+Specialized the ``COMPARE_OP`` opcode using the PEP 659 machinery.
+
+..
+
+.. bpo: 45786
+.. date: 2021-11-23-15-25-00
+.. nonce: UdEciD
+.. section: Core and Builtins
+
+Allocate space for the interpreter frame in the frame object, to avoid an
+additional allocation when the frame object outlives the frame activation.
+
+..
+
+.. bpo: 45614
+.. date: 2021-11-23-12-06-41
+.. nonce: fIekgI
+.. section: Core and Builtins
+
+Fix :mod:`traceback` display for exceptions with invalid module name.
+
+..
+
+.. bpo: 45813
+.. date: 2021-11-22-11-28-13
+.. nonce: ZMaWE2
+.. section: Core and Builtins
+
+Fix crash when calling coro.cr_frame.clear() after coroutine has been freed.
+
+..
+
+.. bpo: 45811
+.. date: 2021-11-20-02-25-06
+.. nonce: B-1Gsr
+.. section: Core and Builtins
+
+Improve the tokenizer errors when encountering invisible control characters
+in the parser. Patch by Pablo Galindo
+
+..
+
+.. bpo: 45848
+.. date: 2021-11-19-22-57-42
+.. nonce: HgVBJ5
+.. section: Core and Builtins
+
+Allow the parser to obtain error lines directly from encoded files. Patch by
+Pablo Galindo
+
+..
+
+.. bpo: 45709
+.. date: 2021-11-19-13-17-47
+.. nonce: H_t7ut
+.. section: Core and Builtins
+
+Restore behavior from 3.10 when tracing an exception raised within a with
+statement.
+
+..
+
+.. bpo: 44525
+.. date: 2021-11-18-10-02-02
+.. nonce: M4xwn_
+.. section: Core and Builtins
+
+Adds new :opcode:`COPY_FREE_VARS` opcode, to make copying of free variables
+from function to frame explicit. Helps optimization of calls to Python
+function.
+
+..
+
+.. bpo: 45829
+.. date: 2021-11-17-10-14-35
+.. nonce: 5Cf6fY
+.. section: Core and Builtins
+
+Specialize :opcode:`BINARY_SUBSCR` for classes with a ``__getitem__`` method
+implemented in Python
+
+..
+
+.. bpo: 45826
+.. date: 2021-11-17-08-05-27
+.. nonce: OERoTm
+.. section: Core and Builtins
+
+Fixed a crash when calling ``.with_traceback(None)`` on ``NameError``. This
+occurs internally in ``unittest.TestCase.assertRaises()``.
+
+..
+
+.. bpo: 45822
+.. date: 2021-11-16-19-41-04
+.. nonce: OT6ueS
+.. section: Core and Builtins
+
+Fixed a bug in the parser that was causing it to not respect :pep:`263`
+coding cookies when no flags are provided. Patch by Pablo Galindo
+
+..
+
+.. bpo: 45820
+.. date: 2021-11-16-19-00-27
+.. nonce: 2X6Psr
+.. section: Core and Builtins
+
+Fix a segfault when the parser fails without reading any input. Patch by
+Pablo Galindo
+
+..
+
+.. bpo: 45636
+.. date: 2021-11-15-13-32-54
+.. nonce: RDlTdL
+.. section: Core and Builtins
+
+Simplify the implementation of :opcode:`BINARY_OP` by indexing into an array
+of function pointers (rather than switching on the oparg).
+
+..
+
+.. bpo: 42540
+.. date: 2021-11-15-12-08-27
+.. nonce: V2w107
+.. section: Core and Builtins
+
+Fix crash when :func:`os.fork` is called with an active non-default memory
+allocator.
+
+..
+
+.. bpo: 45738
+.. date: 2021-11-14-00-14-45
+.. nonce: e0cgKd
+.. section: Core and Builtins
+
+Fix computation of error location for invalid continuation characters in the
+parser. Patch by Pablo Galindo.
+
+..
+
+.. bpo: 45636
+.. date: 2021-11-11-19-11-57
+.. nonce: 2fyIVm
+.. section: Core and Builtins
+
+Remove an existing "fast path" for old-style string formatting, since it no
+longer appears to have any measurable impact.
+
+..
+
+.. bpo: 45753
+.. date: 2021-11-11-17-14-21
+.. nonce: nEBFcC
+.. section: Core and Builtins
+
+Make recursion checks a bit more efficient by tracking amount of calls left
+before overflow.
+
+..
+
+.. bpo: 45773
+.. date: 2021-11-09-13-01-35
+.. nonce: POU8A4
+.. section: Core and Builtins
+
+Fix a compiler hang when attempting to optimize certain jump patterns.
+
+..
+
+.. bpo: 45764
+.. date: 2021-11-09-12-19-22
+.. nonce: 8RLhWL
+.. section: Core and Builtins
+
+The parser now gives a better error message when leaving out the opening
+parenthesis ``(`` after a ``def``-statement::
+
+ >>> def f:
+ File "<stdin>", line 1
+ def f:
+ ^
+ SyntaxError: expected '('
+
+..
+
+.. bpo: 45609
+.. date: 2021-10-27-21-00-49
+.. nonce: L1GKPX
+.. section: Core and Builtins
+
+Specialized the ``STORE_SUBSCR`` opcode using the PEP 659 machinery.
+
+..
+
+.. bpo: 45636
+.. date: 2021-10-27-15-14-31
+.. nonce: K2X7QS
+.. section: Core and Builtins
+
+Replace all numeric ``BINARY_*`` and ``INPLACE_*`` instructions with a
+single :opcode:`BINARY_OP` implementation.
+
+..
+
+.. bpo: 45582
+.. date: 2021-10-23-00-39-31
+.. nonce: YONPuo
+.. section: Core and Builtins
+
+Path calculation (known as ``getpath``) has been reimplemented as a frozen
+Python module. This should have no visible impact, but may affect
+calculation of all paths referenced in :mod:`sys` and :mod:`sysconfig`.
+
+..
+
+.. bpo: 45450
+.. date: 2021-10-12-18-22-44
+.. nonce: d9a-bX
+.. section: Core and Builtins
+
+Improve the syntax error message for parenthesized arguments. Patch by Pablo
+Galindo.
+
+..
+
+.. bpo: 27946
+.. date: 2021-12-04-20-08-42
+.. nonce: -Vuarf
+.. section: Library
+
+Fix possible crash when getting an attribute of
+class:`xml.etree.ElementTree.Element` simultaneously with replacing the
+``attrib`` dict.
+
+..
+
+.. bpo: 45711
+.. date: 2021-12-02-17-22-06
+.. nonce: D6jsdv
+.. section: Library
+
+Make :mod:`asyncio` normalize exceptions as soon as they are captured with
+:c:func:`PyErr_Fetch`, and before they are stored as an exc_info triplet.
+This brings :mod:`asyncio` in line with the rest of the codebase, where an
+exc_info triplet is always normalized.
+
+..
+
+.. bpo: 23819
+.. date: 2021-12-02-14-37-30
+.. nonce: An6vkT
+.. section: Library
+
+Replaced asserts with exceptions in asyncio, patch by Kumar Aditya.
+
+..
+
+.. bpo: 13236
+.. date: 2021-11-30-13-52-02
+.. nonce: FmJIkO
+.. section: Library
+
+:class:`unittest.TextTestResult` and :class:`unittest.TextTestRunner` flush
+now the output stream more often.
+
+..
+
+.. bpo: 45917
+.. date: 2021-11-28-17-24-11
+.. nonce: J5TIrd
+.. section: Library
+
+Added :func:`math.exp2`:, which returns 2 raised to the power of x.
+
+..
+
+.. bpo: 37658
+.. date: 2021-11-28-15-30-34
+.. nonce: 8Hno7d
+.. section: Library
+
+Fix issue when on certain conditions ``asyncio.wait_for()`` may allow a
+coroutine to complete successfully, but fail to return the result,
+potentially causing memory leaks or other issues.
+
+..
+
+.. bpo: 45876
+.. date: 2021-11-23-15-36-56
+.. nonce: NO8Yaj
+.. section: Library
+
+Improve the accuracy of stdev() and pstdev() in the statistics module. When
+the inputs are floats or fractions, the output is a correctly rounded float
+
+..
+
+.. bpo: 44649
+.. date: 2021-11-21-20-50-42
+.. nonce: E8M936
+.. section: Library
+
+Handle dataclass(slots=True) with a field that has default a default value,
+but for which init=False.
+
+..
+
+.. bpo: 45803
+.. date: 2021-11-20-17-04-25
+.. nonce: wSgFOy
+.. section: Library
+
+Added missing kw_only parameter to dataclasses.make_dataclass().
+
+..
+
+.. bpo: 45837
+.. date: 2021-11-18-13-13-19
+.. nonce: aGyr1I
+.. section: Library
+
+The :meth:`turtle.RawTurtle.settiltangle` is deprecated since Python 3.1, it
+now emits a deprecation warning and will be removed in Python 3.13.
+
+Use :meth:`turtle.RawTurtle.tiltangle` instead.
+
+:meth:`turtle.RawTurtle.tiltangle` was earlier incorrectly marked as
+deprecated, its docstring has been corrected.
+
+Patch by Hugo van Kemenade.
+
+..
+
+.. bpo: 45831
+.. date: 2021-11-17-19-25-37
+.. nonce: 9-TojK
+.. section: Library
+
+:mod:`faulthandler` can now write ASCII-only strings (like filenames and
+function names) with a single write() syscall when dumping a traceback. It
+reduces the risk of getting an unreadable dump when two threads or two
+processes dump a traceback to the same file (like stderr) at the same time.
+Patch by Victor Stinner.
+
+..
+
+.. bpo: 45828
+.. date: 2021-11-17-11-40-21
+.. nonce: kQU35U
+.. section: Library
+
+:mod:`sqlite` C callbacks now use unraisable exceptions if callback
+tracebacks are enabled. Patch by Erlend E. Aasland.
+
+..
+
+.. bpo: 41735
+.. date: 2021-11-16-18-13-49
+.. nonce: D72UY1
+.. section: Library
+
+Fix thread lock in ``zlib.Decompress.flush()`` method before
+``PyObject_GetBuffer``.
+
+..
+
+.. bpo: 45235
+.. date: 2021-11-11-13-03-17
+.. nonce: 8ZbkHa
+.. section: Library
+
+Reverted an argparse bugfix that caused regression in the handling of
+default arguments for subparsers. This prevented leaf level arguments from
+taking precedence over root level arguments.
+
+..
+
+.. bpo: 45754
+.. date: 2021-11-09-15-48-38
+.. nonce: c-JDto
+.. section: Library
+
+Fix a regression in Python 3.11a1 and 3.11a2 where :mod:`sqlite3`
+incorrectly would use ``SQLITE_LIMIT_LENGTH`` when checking SQL statement
+lengths. Now, ``SQLITE_LIMIT_SQL_LENGTH`` is used. Patch by Erlend E.
+Aasland.
+
+..
+
+.. bpo: 45766
+.. date: 2021-11-09-09-18-06
+.. nonce: dvbcMf
+.. section: Library
+
+Added *proportional* option to :meth:`statistics.linear_regression`.
+
+..
+
+.. bpo: 45765
+.. date: 2021-11-09-09-04-19
+.. nonce: JVobxK
+.. section: Library
+
+In importlib.metadata, fix distribution discovery for an empty path.
+
+..
+
+.. bpo: 45757
+.. date: 2021-11-08-23-22-14
+.. nonce: MHZHt3
+.. section: Library
+
+Fix bug where :mod:`dis` produced an incorrect oparg when
+:opcode:`EXTENDED_ARG` is followed by an opcode that does not use its
+argument.
+
+..
+
+.. bpo: 45644
+.. date: 2021-11-06-17-47-46
+.. nonce: ZMqHD_
+.. section: Library
+
+In-place JSON file formatting using ``python3 -m json.tool infile infile``
+now works correctly, previously it left the file empty. Patch by Chris
+Wesseling.
+
+..
+
+.. bpo: 45703
+.. date: 2021-11-03-13-41-49
+.. nonce: 35AagL
+.. section: Library
+
+When a namespace package is imported before another module from the same
+namespace is created/installed in a different :data:`sys.path` location
+while the program is running, calling the
+:func:`importlib.invalidate_caches` function will now also guarantee the new
+module is noticed.
+
+..
+
+.. bpo: 45535
+.. date: 2021-10-29-16-28-06
+.. nonce: n8NiOE
+.. section: Library
+
+Improve output of ``dir()`` with Enums.
+
+..
+
+.. bpo: 45664
+.. date: 2021-10-28-23-40-54
+.. nonce: 7dqtxQ
+.. section: Library
+
+Fix :func:`types.resolve_bases` and :func:`types.new_class` for
+:class:`types.GenericAlias` instance as a base.
+
+..
+
+.. bpo: 45663
+.. date: 2021-10-28-23-11-59
+.. nonce: J90N5R
+.. section: Library
+
+Fix :func:`dataclasses.is_dataclass` for dataclasses which are subclasses of
+:class:`types.GenericAlias`.
+
+..
+
+.. bpo: 45662
+.. date: 2021-10-28-22-58-14
+.. nonce: sJd7Ir
+.. section: Library
+
+Fix the repr of :data:`dataclasses.InitVar` with a type alias to the
+built-in class, e.g. ``InitVar[list[int]]``.
+
+..
+
+.. bpo: 43137
+.. date: 2021-10-25-12-51-02
+.. nonce: apo7jY
+.. section: Library
+
+Launch GNOME web browsers via gio tool instead of obsolete gvfs-open
+
+..
+
+.. bpo: 45429
+.. date: 2021-10-25-01-22-49
+.. nonce: VaEyN9
+.. section: Library
+
+On Windows, :func:`time.sleep` now uses a waitable timer which supports
+high-resolution timers. Patch by Dong-hee Na and Eryk Sun.
+
+..
+
+.. bpo: 37295
+.. date: 2021-10-18-16-08-55
+.. nonce: wBEWH2
+.. section: Library
+
+Optimize :func:`math.comb` and :func:`math.perm`.
+
+..
+
+.. bpo: 45514
+.. date: 2021-10-18-14-25-35
+.. nonce: YmlzIl
+.. section: Library
+
+Deprecated legacy functions in :mod:`importlib.resources`.
+
+..
+
+.. bpo: 45507
+.. date: 2021-10-18-14-00-01
+.. nonce: lDotNV
+.. section: Library
+
+Add tests for truncated/missing trailers in gzip.decompress implementation.
+
+..
+
+.. bpo: 45359
+.. date: 2021-10-03-22-27-35
+.. nonce: LX_uxe
+.. section: Library
+
+Implement :pep:`585` for :class:`graphlib.TopologicalSorter`.
+
+..
+
+.. bpo: 44733
+.. date: 2021-07-26-13-33-37
+.. nonce: 88LrP1
+.. section: Library
+
+Add ``max_tasks_per_child`` to
+:class:`concurrent.futures.ProcessPoolExecutor`. This allows users to
+specify the maximum number of tasks a single process should execute before
+the process needs to be restarted.
+
+..
+
+.. bpo: 28806
+.. date: 2021-05-24-13-48-34
+.. nonce: PkNw5D
+.. section: Library
+
+Improve netrc library. netrc file no longer needs to contain all tokens. And
+if the login name is anonymous, security check is no longer need.
+
+..
+
+.. bpo: 43498
+.. date: 2021-04-20-14-14-16
+.. nonce: L_Hq-8
+.. section: Library
+
+Avoid a possible *"RuntimeError: dictionary changed size during iteration"*
+when adjusting the process count of :class:`ProcessPoolExecutor`.
+
+..
+
+.. bpo: 42158
+.. date: 2020-11-10-17-46-12
+.. nonce: OhxAiH
+.. section: Library
+
+Add MIME types for N-quads, N-triples, Notation3 and TriG to ``mimetypes``.
+
+..
+
+.. bpo: 30533
+.. date: 2020-06-16-18-00-56
+.. nonce: StL57t
+.. section: Library
+
+Add :func:`inspect.getmembers_static` , it return all members without
+triggering dynamic lookup via the descriptor protocol. Patch by Weipeng
+Hong.
+
+..
+
+.. bpo: 42238
+.. date: 2021-11-20-02-46-39
+.. nonce: hlfMIc
+.. section: Documentation
+
+``make -C Doc suspicious`` will be removed soon in favor of ``make -C Doc
+check``, mark it as deprecated.
+
+..
+
+.. bpo: 45840
+.. date: 2021-11-19-02-02-32
+.. nonce: A51B2S
+.. section: Documentation
+
+Improve cross-references in the documentation for the data model.
+
+..
+
+.. bpo: 45640
+.. date: 2021-11-18-16-44-12
+.. nonce: lSpc2A
+.. section: Documentation
+
+Properly marked-up grammar tokens in the documentation are now clickable and
+take you to the definition of a given piece of grammar. Patch by Arthur
+Milchior.
+
+..
+
+.. bpo: 45788
+.. date: 2021-11-18-00-07-40
+.. nonce: qibUoB
+.. section: Documentation
+
+Link doc for sys.prefix to sysconfig doc on installation paths.
+
+..
+
+.. bpo: 45772
+.. date: 2021-11-09-13-10-55
+.. nonce: EdrM3t
+.. section: Documentation
+
+``socket.socket`` documentation is corrected to a class from a function.
+
+..
+
+.. bpo: 45392
+.. date: 2021-11-06-10-54-17
+.. nonce: JZnVOz
+.. section: Documentation
+
+Update the docstring of the :class:`type` built-in to remove a redundant
+line and to mention keyword arguments for the constructor.
+
+..
+
+.. bpo: 45250
+.. date: 2021-10-22-12-09-18
+.. nonce: Iit5-Y
+.. section: Documentation
+
+Update the documentation to note that CPython does not consistently require
+iterators to define ``__iter__``.
+
+..
+
+.. bpo: 25381
+.. date: 2021-06-21-17-51-51
+.. nonce: 7Kn-_H
+.. section: Documentation
+
+In the extending chapter of the extending doc, update a paragraph about the
+global variables containing exception information.
+
+..
+
+.. bpo: 43905
+.. date: 2021-05-24-05-00-12
+.. nonce: tBIndE
+.. section: Documentation
+
+Expanded :func:`~dataclasses.astuple` and :func:`~dataclasses.asdict` docs,
+warning about deepcopy being applied and providing a workaround.
+
+..
+
+.. bpo: 45695
+.. date: 2021-12-03-14-19-16
+.. nonce: QKBn2E
+.. section: Tests
+
+Out-of-tree builds with a read-only source directory are now tested by CI.
+
+..
+
+.. bpo: 19460
+.. date: 2021-11-28-15-25-02
+.. nonce: lr0aWs
+.. section: Tests
+
+Add new Test for ``Lib/email/mime/nonmultipart.py::MIMENonMultipart``.
+
+..
+
+.. bpo: 45878
+.. date: 2021-11-23-12-36-21
+.. nonce: eOs_Mp
+.. section: Tests
+
+Test ``Lib/ctypes/test/test_functions.py::test_mro`` now uses
+``self.assertRaises`` instead of ``try/except``.
+
+..
+
+.. bpo: 45835
+.. date: 2021-11-17-14-28-08
+.. nonce: Mgyhjx
+.. section: Tests
+
+Fix race condition in test_queue tests with multiple "feeder" threads.
+
+..
+
+.. bpo: 45783
+.. date: 2021-11-11-13-56-00
+.. nonce: 8k1Rng
+.. section: Tests
+
+The test for the freeze tool now handles file moves and deletions.
+
+..
+
+.. bpo: 45745
+.. date: 2021-11-10-12-01-28
+.. nonce: wX5B3K
+.. section: Tests
+
+Remove the ``--findleaks`` command line option of regrtest: use the
+``--fail-env-changed`` option instead. Since Python 3.7, it was a deprecated
+alias to the ``--fail-env-changed`` option.
+
+..
+
+.. bpo: 45701
+.. date: 2021-10-31-10-58-45
+.. nonce: r0LAUL
+.. section: Tests
+
+Add tests with ``tuple`` type with :func:`functools.lru_cache` to
+``test_functools``.
+
+..
+
+.. bpo: 44035
+.. date: 2021-12-06-09-31-27
+.. nonce: BiO4XC
+.. section: Build
+
+CI now verifies that autoconf files have been regenerated with a current and
+unpatched autoconf package.
+
+..
+
+.. bpo: 45950
+.. date: 2021-12-01-17-28-39
+.. nonce: eEVLoz
+.. section: Build
+
+The build system now uses a :program:`_bootstrap_python` interpreter for
+freezing and deepfreezing again. To speed up build process the build tools
+:program:`_bootstrap_python` and :program:`_freeze_module` are no longer
+build with LTO.
+
+..
+
+.. bpo: 45881
+.. date: 2021-11-29-16-32-55
+.. nonce: 7597J6
+.. section: Build
+
+The :program:`configure` script now accepts ``--with-build-python`` and
+``--with-freeze-module`` options to make cross compiling easier.
+
+..
+
+.. bpo: 40280
+.. date: 2021-11-29-14-37-29
+.. nonce: UlTMR8
+.. section: Build
+
+Emscripten platform now uses ``.wasm`` suffix by default.
+
+..
+
+.. bpo: 40280
+.. date: 2021-11-29-11-24-45
+.. nonce: Knx7d7
+.. section: Build
+
+Disable unusable core extension modules on WASM/Emscripten targets.
+
+..
+
+.. bpo: 40280
+.. date: 2021-11-26-14-09-04
+.. nonce: ZLpwQf
+.. section: Build
+
+``configure`` now checks for socket ``shutdown`` function. The check makes
+it possible to disable ``SYS_shutdown`` with ``ac_cv_func_shutdown=no`` in
+CONFIG_SITE.
+
+..
+
+.. bpo: 40280
+.. date: 2021-11-26-09-10-19
+.. nonce: xmiMJl
+.. section: Build
+
+``configure`` now checks for functions ``fork1, getegid, geteuid, getgid,
+getppid, getuid, opendir, pipe, system, wait, ttyname``.
+
+..
+
+.. bpo: 33393
+.. date: 2021-11-25-20-26-06
+.. nonce: 24YNtM
+.. section: Build
+
+Update ``config.guess`` to 2021-06-03 and ``config.sub`` to 2021-08-14.
+``Makefile`` now has an ``update-config`` target to make updating more
+convenient.
+
+..
+
+.. bpo: 45866
+.. date: 2021-11-25-13-53-36
+.. nonce: ZH1W8N
+.. section: Build
+
+``make regen-all`` now produces the same output when run from a directory
+other than the source tree: when building Python out of the source tree.
+pegen now strips directory of the "generated by pygen from <FILENAME>"
+header Patch by Victor Stinner.
+
+..
+
+.. bpo: 40280
+.. date: 2021-11-25-10-55-03
+.. nonce: E9-gsQ
+.. section: Build
+
+``configure`` now accepts machine ``wasm32`` or ``wasm64`` and OS ``wasi``
+or ``emscripten`` for cross building, e.g. ``wasm32-unknown-emscripten``,
+``wasm32-wasi``, or ``wasm32-unknown-wasi``.
+
+..
+
+.. bpo: 41498
+.. date: 2021-11-25-09-15-04
+.. nonce: qAk5eo
+.. section: Build
+
+Python now compiles on platforms without ``sigset_t``. Several functions in
+:mod:`signal` are not available when ``sigset_t`` is missing.
+
+Based on patch by Roman Yurchak for pyodide.
+
+..
+
+.. bpo: 45881
+.. date: 2021-11-24-17-14-06
+.. nonce: GTXXLk
+.. section: Build
+
+``setup.py`` now uses ``CC`` from environment first to discover multiarch
+and cross compile paths.
+
+..
+
+.. bpo: 45886
+.. date: 2021-11-23-23-37-49
+.. nonce: _Ulnh-
+.. section: Build
+
+The ``_freeze_module`` program path can now be overridden on the command
+line, e.g. ``make FREEZE_MODULE=../x86_64/Program/_freeze_module``.
+
+..
+
+.. bpo: 45873
+.. date: 2021-11-23-04-28-40
+.. nonce: 9dldZ4
+.. section: Build
+
+Get rid of the ``_bootstrap_python`` build step. The deepfreeze.py script is
+now run using ``$(PYTHON_FOR_REGEN)`` which can be Python 3.7 or newer (on
+Windows, 3.8 or newer).
+
+..
+
+.. bpo: 45847
+.. date: 2021-11-19-17-57-57
+.. nonce: 9phcpd
+.. section: Build
+
+Port builtin hashlib extensions to ``PY_STDLIB_MOD`` macro and ``addext()``.
+
+..
+
+.. bpo: 45723
+.. date: 2021-11-19-15-42-27
+.. nonce: vwIJWI
+.. section: Build
+
+Add ``autoconf`` helpers for saving and restoring environment variables:
+
+* ``SAVE_ENV``: Save ``$CFLAGS``, ``$LDFLAGS``, ``$LIBS``, and
+ ``$CPPFLAGS``.
+* ``RESTORE_ENV``: Restore ``$CFLAGS``, ``$LDFLAGS``, ``$LIBS``, and
+ ``$CPPFLAGS``.
+* ``WITH_SAVE_ENV([SCRIPT])``: Run ``SCRIPT`` wrapped with ``SAVE_ENV`` and
+ ``RESTORE_ENV``.
+
+Patch by Erlend E. Aasland.
+
+..
+
+.. bpo: 45573
+.. date: 2021-11-18-13-31-02
+.. nonce: LCjGB8
+.. section: Build
+
+Mandatory core modules, that are required to bootstrap Python, are now in
+``Modules/Setup.bootstrap``.
+
+..
+
+.. bpo: 45573
+.. date: 2021-11-18-12-18-43
+.. nonce: xsMZzn
+.. section: Build
+
+``configure`` now creates ``Modules/Setup.stdlib`` with conditionally
+enabled/disabled extension module lines. The file is not used, yet.
+
+..
+
+.. bpo: 45573
+.. date: 2021-11-17-19-02-51
+.. nonce: GMNdun
+.. section: Build
+
+``configure`` now uses a unified format to set state, compiler flags, and
+linker flags in Makefile. The new macro ``PY_STDLIB_MOD`` sets three
+variables that are consumed by ``Modules/Setup`` and ``setup.py``.
+
+..
+
+.. bpo: 45816
+.. date: 2021-11-16-14-44-06
+.. nonce: nbdmVK
+.. section: Build
+
+Python now supports building with Visual Studio 2022 (MSVC v143, VS Version
+17.0). Patch by Jeremiah Vivian.
+
+..
+
+.. bpo: 45800
+.. date: 2021-11-13-16-40-05
+.. nonce: 5Hz6nr
+.. section: Build
+
+Settings for :mod:`pyexpat` C extension are now detected by ``configure``.
+The bundled ``expat`` library is built in ``Makefile``.
+
+..
+
+.. bpo: 45798
+.. date: 2021-11-13-10-18-22
+.. nonce: IraaTs
+.. section: Build
+
+Settings for :mod:`decimal` internal C extension are now detected by
+``configure``. The bundled ``libmpdec`` library is built in ``Makefile``.
+
+..
+
+.. bpo: 45723
+.. date: 2021-11-10-16-13-02
+.. nonce: B5gCB1
+.. section: Build
+
+:program:`configure` has a new option ``--with-pkg-config`` to disable or
+require pkg-config.
+
+..
+
+.. bpo: 45774
+.. date: 2021-11-09-23-30-12
+.. nonce: Mwm3ZR
+.. section: Build
+
+The build dependencies for :mod:`sqlite3` are now detected by ``configure``
+and ``pkg-config``. Patch by Erlend E. Aasland.
+
+..
+
+.. bpo: 45763
+.. date: 2021-11-09-10-15-33
+.. nonce: gP-vrX
+.. section: Build
+
+The build dependencies for :mod:`zlib`, :mod:`bz2`, and :mod:`lzma` are now
+detected by ``configure``.
+
+..
+
+.. bpo: 45747
+.. date: 2021-11-08-11-31-48
+.. nonce: AODmk_
+.. section: Build
+
+gdbm and dbm build dependencies are now detected by ``configure``.
+
+..
+
+.. bpo: 45743
+.. date: 2021-11-08-08-58-06
+.. nonce: fZ8CTi
+.. section: Build
+
+On macOS, the build system no longer passes ``search_paths_first`` to the
+linker. The flag has been the default since Xcode 4 / macOS 10.6.
+
+..
+
+.. bpo: 45723
+.. date: 2021-11-07-10-45-40
+.. nonce: AreusF
+.. section: Build
+
+``configure.ac`` is now compatible with autoconf 2.71. Deprecated checks
+``STDC_HEADERS`` and ``AC_HEADER_TIME`` have been removed.
+
+..
+
+.. bpo: 45723
+.. date: 2021-11-07-10-36-12
+.. nonce: JNwKSG
+.. section: Build
+
+``configure`` now prints a warning when pkg-config is missing.
+
+..
+
+.. bpo: 45731
+.. date: 2021-11-05-20-56-29
+.. nonce: 9SDnDf
+.. section: Build
+
+``configure --enable-loadable-sqlite-extensions`` is now handled by new
+``PY_SQLITE_ENABLE_LOAD_EXTENSION`` macro instead of logic in setup.py.
+
+..
+
+.. bpo: 45723
+.. date: 2021-11-05-15-09-49
+.. nonce: gfSxur
+.. section: Build
+
+configure.ac now uses custom helper macros and ``AC_CACHE_CHECK`` to
+simplify and speed up configure runs.
+
+..
+
+.. bpo: 45696
+.. date: 2021-11-03-00-19-50
+.. nonce: eKs46f
+.. section: Build
+
+Skip the marshal step for frozen modules by generating C code that produces
+a set of ready-to-use code objects. This speeds up startup time by another
+10% or more.
+
+..
+
+.. bpo: 45561
+.. date: 2021-10-21-14-38-30
+.. nonce: PVqhZE
+.. section: Build
+
+Run smelly.py tool from $(srcdir).
+
+..
+
+.. bpo: 46105
+.. date: 2021-12-08-16-36-20
+.. nonce: t1mJ6Q
+.. section: Windows
+
+Fixed calculation of :data:`sys.path` in a venv on Windows.
+
+..
+
+.. bpo: 45901
+.. date: 2021-11-26-18-17-41
+.. nonce: c5IBqM
+.. section: Windows
+
+When installed through the Microsoft Store and set as the default app for
+:file:`*.py` files, command line arguments will now be passed to Python when
+invoking a script without explicitly launching Python (that is, ``script.py
+args`` rather than ``python script.py args``).
+
+..
+
+.. bpo: 45616
+.. date: 2021-11-23-11-44-42
+.. nonce: K52PLZ
+.. section: Windows
+
+Fix Python Launcher's ability to distinguish between versions 3.1 and 3.10
+when either one is explicitly requested. Previously, 3.1 would be used if
+3.10 was requested but not installed, and 3.10 would be used if 3.1 was
+requested but 3.10 was installed.
+
+..
+
+.. bpo: 45850
+.. date: 2021-11-20-00-06-59
+.. nonce: q9lofz
+.. section: Windows
+
+Implement changes to build with deep-frozen modules on Windows. Note that we
+now require Python 3.10 as the "bootstrap" or "host" Python.
+
+..
+
+.. bpo: 45732
+.. date: 2021-11-08-21-53-11
+.. nonce: idl5kx
+.. section: Windows
+
+Updates bundled Tcl/Tk to 8.6.12.
+
+..
+
+.. bpo: 45720
+.. date: 2021-11-05-01-05-46
+.. nonce: 47Nc5I
+.. section: Windows
+
+Internal reference to :file:`shlwapi.dll` was dropped to help improve
+startup time. This DLL will no longer be loaded at the start of every Python
+process.
+
+..
+
+.. bpo: 45732
+.. date: 2021-12-05-23-52-03
+.. nonce: -BWrnh
+.. section: macOS
+
+Update python.org macOS installer to use Tcl/Tk 8.6.12.
+
+..
+
+.. bpo: 39026
+.. date: 2021-11-09-15-42-11
+.. nonce: sUnYWn
+.. section: C API
+
+Fix Python.h to build C extensions with Xcode: remove a relative include
+from ``Include/cpython/pystate.h``.