Test object_hook and pickleability of some JSON components#154155
Conversation
dslavicek
commented
Jul 19, 2026
- add test for object hook in JSONDecoder
- add test of pickleability of JsonDecodeError
| @@ -0,0 +1,14 @@ | |||
| import json | |||
There was a problem hiding this comment.
@encukou advised me not to put this in the file with decoder tests. I saw no existing dedicated file for testing pickling of things from the json module. Where do you propose placing the test?
There was a problem hiding this comment.
Ah I see. I guess, it's fine then (I wasn't aware of the rationale so it was surprsing).
There was a problem hiding this comment.
Also, all other JSON tests run twice, with speedups (_json) enabled/disabled, but this doesn't sit well with pickle.
This comment was marked as off-topic.
This comment was marked as off-topic.
object_hook and pickleability of json decoders
object_hook and pickleability of json decodersobject_hook and pickleability of some JSON components
|
Thanks @dslavicek for the PR, and @encukou for merging it 🌮🎉.. I'm working now to backport this PR to: 3.14, 3.15. |
|
GH-154374 is a backport of this pull request to the 3.15 branch. |
|
GH-154375 is a backport of this pull request to the 3.14 branch. |