Skip to main content

extraction_failure

Function extraction_failure 

Source
pub fn extraction_failure(
    kind: &str,
    ob: &Bound<'_, PyAny>,
    cause: impl Display,
) -> PyErr
Expand description

Build a PyErr for a failed AST-node conversion, carrying the node’s source position so the error can be reported against the user’s Python code instead of panicking with an internal dump.