The json module handles only a fixed set of Python types. To serialize complex numbers, dates, paths, or user-defined classes you must supply a default function or subclass JSONEncoder, then pair the output with object_hook on the decode side.
json / serialization / JSONEncoder / default / object_hook / python-standard-library / datetime / complex
Learn how to parse JSON data in Python from both string literals and files, and how to effectively handle potential decoding errors using the built-in json module.
python / json / parsing / decoding / file handling / error handling / pathlib / data serialization
A guide to using the Python csv module to automatically detect delimiters, handle Unicode Byte Order Marks (BOM) with utf-8-sig, and manage platform-specific newline issues using the Sniffer class and correct file opening parameters.
python / csv / data-processing / encoding / utf-8-sig / automation