Commit dbdabcf2 authored by Markus Scheidgen's avatar Markus Scheidgen
Browse files

Fixed metainfo dependency loading recursion issue.

parent 7cb9a1ed
......@@ -139,7 +139,6 @@ async function archive(uploadId, calcId) {
async function calcProcLog(uploadId, calcId) {
const client = await swaggerPromise
console.log(uploadId + calcId)
return client.apis.archive.get_archive_logs({
upload_id: uploadId,
calc_id: calcId
......@@ -216,18 +215,24 @@ async function getMetaInfo() {
.catch(handleJsonErrors)
.then(data => {
if (!cachedMetaInfo) {
cachedMetaInfo = {}
}
if (data.dependencies) {
data.dependencies.forEach(dep => {
loadMetaInfo(dep.relativePath)
})
cachedMetaInfo = {
loadedDependencies: {}
}
}
cachedMetaInfo.loadedDependencies[path] = true
if (data.metaInfos) {
data.metaInfos.forEach(info => {
cachedMetaInfo[info.name] = info
info.relativePath = path
})
}
if (data.dependencies) {
data.dependencies
.filter(dep => cachedMetaInfo.loadedDependencies[dep.relativePath] !== true)
.forEach(dep => {
loadMetaInfo(dep.relativePath)
})
}
})
}
await loadMetaInfo('all.nomadmetainfo.json')
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment