Spine-Toolbox
Spine-Toolbox copied to clipboard
Importer errors for empty rows
Objective: import data from the sheet that lists all entities (generators) in one column and lists specific subsets of entities (generators of certain type) in the following columns. Mapping chosen: fist column - zero dimension entities without parameters, subsequent columns - zero dimension entity with constant parameter value (set as generator type). Result (if run without cancelling on error) - as expected imports entities with parameters specifying their type. Error log lists errors of importing the last element in each subset column. Errors are repeat number of times that correspond to empty errors in the column until end of the first column. Example of the error message in the error log: attempting to import more than one parameter_value with {'entity_class_name': 'Generator', 'entity_byname': ('Hydro run-of-the-river',), 'parameter_definition_name': 'Type', 'alternative_name': 'Importer@2024-05-03T17:58:07'} - only first will be considered The attached zip file contains Spine Toolbox project with importer that produce this error. Bug - empty row.zip
Not sure if this is an actual bug. The Excel file does not represent the information in a format that would allow to deduce what sub-category belongs to which category. The Excel file could be imported in a way that makes three separate entity_classes though.
The errors should be gone once you update spinedb_api
.