polars_python/
exceptions.rs1use pyo3::create_exception;
4use pyo3::exceptions::{PyException, PyWarning};
5
6create_exception!(polars.exceptions, PolarsError, PyException);
8create_exception!(polars.exceptions, ColumnNotFoundError, PolarsError);
9create_exception!(polars.exceptions, ComputeError, PolarsError);
10create_exception!(polars.exceptions, DuplicateError, PolarsError);
11create_exception!(polars.exceptions, InvalidOperationError, PolarsError);
12create_exception!(polars.exceptions, NoDataError, PolarsError);
13create_exception!(polars.exceptions, OutOfBoundsError, PolarsError);
14create_exception!(polars.exceptions, SQLInterfaceError, PolarsError);
15create_exception!(polars.exceptions, SQLSyntaxError, PolarsError);
16create_exception!(polars.exceptions, SchemaError, PolarsError);
17create_exception!(polars.exceptions, SchemaFieldNotFoundError, PolarsError);
18create_exception!(polars.exceptions, ShapeError, PolarsError);
19create_exception!(polars.exceptions, StringCacheMismatchError, PolarsError);
20create_exception!(polars.exceptions, StructFieldNotFoundError, PolarsError);
21
22create_exception!(polars.exceptions, PolarsWarning, PyWarning);
24create_exception!(polars.exceptions, PerformanceWarning, PolarsWarning);
25create_exception!(
26 polars.exceptions,
27 CategoricalRemappingWarning,
28 PerformanceWarning
29);
30create_exception!(
31 polars.exceptions,
32 MapWithoutReturnDtypeWarning,
33 PolarsWarning
34);