dump_json
- dump_json(key: str, *subkeys: str, name: str, obj: Any, open_kwargs: Mapping[str, Any] | None = None, json_dump_kwargs: Mapping[str, Any] | None = None) None[source]
Dump an object to a file with
json.- Parameters:
key – The module name
subkeys – A sequence of additional strings to join. If none are given, returns the directory for this module.
name – The name of the file to open
obj – The object to dump
open_kwargs – Additional keyword arguments passed to
open()json_dump_kwargs – Keyword arguments to pass through to
json.dump().