bpo-42360: Add advice to help avoid pickling issues. (GH-23305)

This commit is contained in:
Raymond Hettinger 2020-11-20 12:49:32 -08:00 committed by GitHub
parent 4c24b08cd3
commit 9fc319dc03
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -862,6 +862,9 @@ they add the ability to access fields by name instead of position index.
Named tuple instances do not have per-instance dictionaries, so they are
lightweight and require no more memory than regular tuples.
To support pickling, the named tuple class should be assigned to a variable
that matches *typename*.
.. versionchanged:: 3.1
Added support for *rename*.