Compare commits
2 Commits
6ad5fd1482
...
a34ab8188e
Author | SHA1 | Date |
---|---|---|
Miss Islington (bot) | a34ab8188e | |
kj | 597ebc8cf6 |
|
@ -197,7 +197,9 @@ Module functions and constants
|
|||
|
||||
*detect_types* defaults to 0 (i. e. off, no type detection), you can set it to
|
||||
any combination of :const:`PARSE_DECLTYPES` and :const:`PARSE_COLNAMES` to turn
|
||||
type detection on.
|
||||
type detection on. Due to SQLite behaviour, types can't be detected for generated
|
||||
fields (for example ``max(data)``), even when *detect_types* parameter is set. In
|
||||
such case, the returned type is :class:`str`.
|
||||
|
||||
By default, *check_same_thread* is :const:`True` and only the creating thread may
|
||||
use the connection. If set :const:`False`, the returned connection may be shared
|
||||
|
|
|
@ -260,6 +260,9 @@ Standard names are defined for the following types:
|
|||
|
||||
.. versionadded:: 3.9
|
||||
|
||||
.. versionchanged:: 3.9.2
|
||||
This type can now be subclassed.
|
||||
|
||||
|
||||
.. class:: TracebackType(tb_next, tb_frame, tb_lasti, tb_lineno)
|
||||
|
||||
|
|
|
@ -1497,3 +1497,22 @@ functions and options conditionally available based on the operating system
|
|||
version in use at runtime ("weaklinking").
|
||||
|
||||
(Contributed by Ronald Oussoren and Lawrence D'Anna in :issue:`41100`.)
|
||||
|
||||
Notable changes in Python 3.9.2
|
||||
===============================
|
||||
|
||||
collections.abc
|
||||
---------------
|
||||
|
||||
:class:`collections.abc.Callable` generic now flattens type parameters, similar
|
||||
to what :data:`typing.Callable` currently does. This means that
|
||||
``collections.abc.Callable[[int, str], str]`` will have ``__args__`` of
|
||||
``(int, str, str)``; previously this was ``([int, str], str)``. To allow this
|
||||
change, :class:`types.GenericAlias` can now be subclassed, and a subclass will
|
||||
be returned when subscripting the :class:`collections.abc.Callable` type.
|
||||
Code which accesses the arguments via :func:`typing.get_args` or ``__args__``
|
||||
need to account for this change. A :exc:`DeprecationWarning` may be emitted for
|
||||
invalid forms of parameterizing :class:`collections.abc.Callable` which may have
|
||||
passed silently in Python 3.9.1. This :exc:`DeprecationWarning` will
|
||||
become a :exc:`TypeError` in Python 3.10.
|
||||
(Contributed by Ken Jin in :issue:`42195`.)
|
||||
|
|
Loading…
Reference in New Issue