classification
Title: Incorrect signatures of object.__reduce__() and object.__reduce_ex__()
Type: behavior Stage: resolved
Components: Interpreter Core Versions: Python 3.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: serhiy.storchaka Nosy List: alexandre.vassalotti, serhiy.storchaka
Priority: normal Keywords:

Created on 2017-03-27 08:01 by serhiy.storchaka, last changed 2017-04-08 06:56 by serhiy.storchaka. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 843 merged serhiy.storchaka, 2017-03-27 08:12
Messages (2)
msg290567 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-03-27 08:01
The special method __reduce__() doesn't take arguments, the special method __reduce_ex__() takes one mandatory argument. But default implementations in the object class takes one optional argument. This looks as an oversign. Proposed patch fixes signatures of object.__reduce__() and object.__reduce_ex__().
msg291323 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-04-08 06:53
New changeset 205e00c5cfd495a4dc6dae8e8fa0fb828fb3dca9 by Serhiy Storchaka in branch 'master':
bpo-29914: Fix default implementations of __reduce__ and __reduce_ex__(). (#843)
https://github.com/python/cpython/commit/205e00c5cfd495a4dc6dae8e8fa0fb828fb3dca9
History
Date User Action Args
2017-04-08 06:56:08serhiy.storchakasetstatus: open -> closed
resolution: fixed
stage: patch review -> resolved
2017-04-08 06:53:01serhiy.storchakasetmessages: + msg291323
2017-04-07 15:50:25serhiy.storchakasetassignee: serhiy.storchaka
2017-03-27 08:12:13serhiy.storchakasetpull_requests: + pull_request740
2017-03-27 08:01:08serhiy.storchakacreate