@hestia-earth/ui-components 0.42.9 → 0.42.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -9018,6 +9018,8 @@ const parseLookup = ({ column, termid, 'term.id': _termid, [missingLookupPrefix]
|
|
|
9018
9018
|
});
|
|
9019
9019
|
const hasValue = (value) => !!value && value !== noValue;
|
|
9020
9020
|
const parseFilename = (filepath) => {
|
|
9021
|
+
if (!filepath)
|
|
9022
|
+
return '';
|
|
9021
9023
|
const [filename] = filepath.split('.');
|
|
9022
9024
|
const ext = termTypes.includes(filename) ? SupportedExtensions.xlsx : SupportedExtensions.csv;
|
|
9023
9025
|
return fileToExt(filename, ext);
|
|
@@ -9240,9 +9242,15 @@ const jLogEntryToLog = (entry) => {
|
|
|
9240
9242
|
const { model, orchestrator, should_run, run_required, methodTier, model_key, is_not_relevant, missingLookup, ...rest } = entry;
|
|
9241
9243
|
const logs = pickFields(rest, key => modelLogKeys.includes(key));
|
|
9242
9244
|
const requirements = pickFields(rest, key => !modelLogKeys.includes(key));
|
|
9243
|
-
// the `.jlog` lists missing lookups per entry
|
|
9244
|
-
// "Data missing (might be optional)"
|
|
9245
|
-
const missingLookups = Array.isArray(missingLookup)
|
|
9245
|
+
// the `.jlog` lists missing lookups per entry (`{ lookup, row, row_value, column }`); map them to the
|
|
9246
|
+
// shared "Data missing (might be optional)" shape, reusing the legacy filename parser
|
|
9247
|
+
const missingLookups = Array.isArray(missingLookup)
|
|
9248
|
+
? missingLookup.map(({ lookup, row_value, column }) => ({
|
|
9249
|
+
filename: parseFilename(lookup),
|
|
9250
|
+
termId: row_value,
|
|
9251
|
+
column
|
|
9252
|
+
}))
|
|
9253
|
+
: [];
|
|
9246
9254
|
return {
|
|
9247
9255
|
// keep the untouched `.jlog` entry so the popover can show the raw JSON
|
|
9248
9256
|
raw: entry,
|