get_mappings

static NotebookParser.get_mappings() Iterator[tuple[str, str, InputLineMapping]][source]

Return the mapping information needed to generate error messages.

The message corresponds to the original notebook and not the actually checked parsed one.

Returns:

(original_notebook_paths, intermediate_py_file_paths, input_line_mappings) original_notebook_paths is the relative path of the tested notebook. intermediate_py_file_paths is the absolute path of the checked notebook. And input_line_mapping is a dict of information about which input in the original notebook, is in what line in the corresponding pared notebook.

Return type:

Iterator[tuple[str, str, InputLineMapping]]

See also

input_line_mapping, create_intermediate_py_file