terra.exceptions

 1#  Copyright 2022 Terra Enabling Developers Limited
 2#
 3#  Licensed under the Apache License, Version 2.0 (the "License");
 4#  you may not use this file except in compliance with the License.
 5#  You may obtain a copy of the License at
 6#
 7#      http://www.apache.org/licenses/LICENSE-2.0
 8#
 9#  Unless required by applicable law or agreed to in writing, software
10#  distributed under the License is distributed on an "AS IS" BASIS,
11#  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12#  See the License for the specific language governing permissions and
13#  limitations under the License.
14__all__ = ["TerraException", "NoDtypeException", "NoBodyException", "NoUserInfoException", "NoClientAvailable"]
15
16
17class TerraException(Exception):
18    """Base class for all exceptions raised by this library"""
19
20
21class NoClientAvailable(TerraException):
22    """
23    Exception raised when a TerraUser object has no Terra client set,
24    but a method requiring it is called.
25    """
26
27
28class NoBodyException(TerraException):
29    """
30    Exception raised when a TerraApi object has no body
31    """
32
33
34class NoUserInfoException(TerraException):
35    """
36    Exception raised when a UserInfoDict is None
37    """
38
39
40class NoDtypeException(TerraException):
41    """
42    Exception raised when a TerraPi object has no dtype
43    """
class TerraException(builtins.Exception):
18class TerraException(Exception):
19    """Base class for all exceptions raised by this library"""

Base class for all exceptions raised by this library

Inherited Members
builtins.Exception
Exception
builtins.BaseException
with_traceback
args
class NoDtypeException(TerraException):
41class NoDtypeException(TerraException):
42    """
43    Exception raised when a TerraPi object has no dtype
44    """

Exception raised when a TerraPi object has no dtype

Inherited Members
builtins.Exception
Exception
builtins.BaseException
with_traceback
args
class NoBodyException(TerraException):
29class NoBodyException(TerraException):
30    """
31    Exception raised when a TerraApi object has no body
32    """

Exception raised when a TerraApi object has no body

Inherited Members
builtins.Exception
Exception
builtins.BaseException
with_traceback
args
class NoUserInfoException(TerraException):
35class NoUserInfoException(TerraException):
36    """
37    Exception raised when a UserInfoDict is None
38    """

Exception raised when a UserInfoDict is None

Inherited Members
builtins.Exception
Exception
builtins.BaseException
with_traceback
args
class NoClientAvailable(TerraException):
22class NoClientAvailable(TerraException):
23    """
24    Exception raised when a TerraUser object has no Terra client set,
25    but a method requiring it is called.
26    """

Exception raised when a TerraUser object has no Terra client set, but a method requiring it is called.

Inherited Members
builtins.Exception
Exception
builtins.BaseException
with_traceback
args