Inmanta Compile Data Reference¶
This page documents the compile data output when compiling with the –export-compile-data flag. The structure
of this JSON is defined by inmanta.data.model.CompileData
which inherits
from pydantic.BaseModel
. To produce the JSON representation of the object, model.json() is called. See the
pydantic documentation
for more information on how exactly a JSON is generated from a model.
- class inmanta.data.model.CompileData(*, errors: List[inmanta.ast.export.Error])[source]¶
Bases:
inmanta.data.model.BaseModel
Top level structure of compiler data to be exported.
- errors: List[inmanta.ast.export.Error]¶
All errors occurred while trying to compile.
- class inmanta.ast.export.Error(*, category: inmanta.ast.export.ErrorCategory = ErrorCategory.runtime, type: str, message: str, location: inmanta.ast.export.Location = None, **extra_data: Any)[source]¶
Bases:
pydantic.main.BaseModel
Error occurred while trying to compile.
- category: inmanta.ast.export.ErrorCategory¶
Category of this error.
- location: Optional[inmanta.ast.export.Location]¶
Location where this error occurred.
- message: str¶
Error message.
- type: str¶
Fully qualified name of the actual exception.
- class inmanta.ast.export.ErrorCategory(value)[source]¶
Bases:
str
,enum.Enum
Category of an error.
- parser = 'parse_error'¶
Error occurred while parsing.
- plugin = 'plugin_exception'¶
A plugin explicitly raised an
inmanta.plugins.PluginException
.
- runtime = 'runtime_error'¶
Error occurred after parsing.
- class inmanta.ast.export.Location(*, uri: str, range: inmanta.ast.export.Range)[source]¶
Bases:
pydantic.main.BaseModel
Location in a file. Based on the LSP spec 3.15
- range: inmanta.ast.export.Range¶
- uri: str¶
- class inmanta.ast.export.Range(*, start: inmanta.ast.export.Position, end: inmanta.ast.export.Position)[source]¶
Bases:
pydantic.main.BaseModel
Range in a file. Based on the LSP spec 3.15
- start: inmanta.ast.export.Position¶
- class inmanta.ast.export.Position(*, line: int, character: int)[source]¶
Bases:
pydantic.main.BaseModel
Position in a file. Based on the LSP spec 3.15
- character: int¶
- line: int¶