5.3.1.22.5.2. cli.db.setup.read_json
- cli.db.setup.read_json(json_file: Path | Path, directory: Path | Path) dict
Read a JSON file from a filesystem path or ZIP virtual path.
- Parameters:
json_file – Path to the JSON file inside a directory or ZIP archive.
directory – The parent directory, used only for reporting in error messages.
- Returns:
Parsed JSON content as dictionary.
- Raises:
SystemExit – If the JSON file does not exist.
JSONDecodeError – Propagated if the file content is not valid JSON.