Base
cognite.neat.issues
#
This is module contains all the Neat Exceptions (Errors) and Warnings as well as some helper classes to handle them like NeatIssueList
DefaultWarning
dataclass
#
Bases: NeatWarning
{category}: {warning}
Source code in cognite/neat/issues/_base.py
IssueList
#
MultiValueError
#
Bases: ValueError
This is a container for multiple errors.
It is used in the pydantic field_validator/model_validator to collect multiple errors, which can then be caught in a try-except block and returned as an IssueList.
Source code in cognite/neat/issues/_base.py
NeatError
dataclass
#
Bases: NeatIssue
, Exception
This is the base class for all exceptions (errors) used in Neat.
Source code in cognite/neat/issues/_base.py
from_pydantic_errors(errors, **kwargs)
classmethod
#
Convert a list of pydantic errors to a list of Error instances.
This is intended to be overridden in subclasses to handle specific error types.
Source code in cognite/neat/issues/_base.py
NeatIssue
dataclass
#
This is the base class for all exceptions and warnings (issues) used in Neat.
Source code in cognite/neat/issues/_base.py
62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 |
|
as_message()
#
Return a human-readable message for the issue.
Source code in cognite/neat/issues/_base.py
dump()
#
Return a dictionary representation of the issue.
Source code in cognite/neat/issues/_base.py
load(data)
classmethod
#
Create an instance of the issue from a dictionary.
Source code in cognite/neat/issues/_base.py
NeatIssueList
#
Bases: UserList[T_NeatIssue]
, Sequence[T_NeatIssue]
, ABC
This is a generic list of NeatIssues.
Source code in cognite/neat/issues/_base.py
errors: Self
property
#
Return all the errors in this list.
has_errors: bool
property
#
Return True if this list contains any errors.
warnings: Self
property
#
Return all the warnings in this list.
as_errors()
#
Return an ExceptionGroup with all the errors in this list.
trigger_warnings()
#
to_pandas()
#
NeatWarning
dataclass
#
Bases: NeatIssue
, UserWarning
This is the base class for all warnings used in Neat.