exceptions.pyi 751 B

12345678910111213141516171819202122232425
  1. from typing import overload
  2. __all__ = [
  3. "ComplexWarning",
  4. "VisibleDeprecationWarning",
  5. "ModuleDeprecationWarning",
  6. "TooHardError",
  7. "AxisError",
  8. "DTypePromotionError",
  9. ]
  10. class ComplexWarning(RuntimeWarning): ...
  11. class ModuleDeprecationWarning(DeprecationWarning): ...
  12. class VisibleDeprecationWarning(UserWarning): ...
  13. class RankWarning(RuntimeWarning): ...
  14. class TooHardError(RuntimeError): ...
  15. class DTypePromotionError(TypeError): ...
  16. class AxisError(ValueError, IndexError):
  17. axis: None | int
  18. ndim: None | int
  19. @overload
  20. def __init__(self, axis: str, ndim: None = ..., msg_prefix: None = ...) -> None: ...
  21. @overload
  22. def __init__(self, axis: int, ndim: int, msg_prefix: None | str = ...) -> None: ...