bpo-45335: Add note to `sqlite3` docs about "timestamp" converter (GH-29200) (GH-29319)

(cherry picked from commit 3877fc02f7)

Co-authored-by: Ian Fisher <ian@iafisher.com>
This commit is contained in:
Miss Islington (bot) 2021-10-29 13:41:45 -07:00 committed by GitHub
parent d8ca47c943
commit 8ea665c730
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 0 deletions

View File

@ -1072,6 +1072,12 @@ If a timestamp stored in SQLite has a fractional part longer than 6
numbers, its value will be truncated to microsecond precision by the
timestamp converter.
.. note::
The default "timestamp" converter ignores UTC offsets in the database and
always returns a naive :class:`datetime.datetime` object. To preserve UTC
offsets in timestamps, either leave converters disabled, or register an
offset-aware converter with :func:`register_converter`.
.. _sqlite3-controlling-transactions: