notebook_cell_to_intermediate_dict

notebook_cell_to_intermediate_dict(notebook_cell: NotebookCell) dict[str, CellId | str | int][source]

Parse notebook_cell to a dict.

That dict can later be written to a intermediate_py_file.

Parameters:

notebook_cell (NotebookCell) – Dict representation of a notebook cell as parsed from JSON.

Returns:

Dict which has the keys ‘code’, ‘input_name’ and ‘code’. code,``input_name`` is a str of the code cells In[\d\*] name and lines_of_code is the number of lines of corresponding parsed parsed notebook cell.

Return type:

dict[str, CellId | str | int]