[*] Cleaner error messages
This commit is contained in:
parent
5b4db53fc5
commit
db718bebe1
@ -8,7 +8,7 @@ _auProjectsBlocked = {}
|
||||
_auNamespacesEmitted = {}
|
||||
_auResolvedDep = {}
|
||||
_auCurrentProject = {}
|
||||
_auCurrentBaseProject = {}
|
||||
_auCurrentBaseProject = nil
|
||||
_auFatalMsg = {}
|
||||
|
||||
-------------------------------------------------------
|
||||
@ -193,28 +193,36 @@ local function initializeDependencyTree(proj, resolveProject)
|
||||
if (not proj.resolvedDeps) then
|
||||
if (proj.processor.resolveDependencies) then
|
||||
pushProject(proj, function()
|
||||
_auFatalMsg = {}
|
||||
_auFatalMsg["starting resolve dependencies"] = proj.info.name
|
||||
|
||||
local depRecursive = _auFatalMsg.deps or {}
|
||||
_auFatalMsg.deps = depRecursive
|
||||
|
||||
proj.processor:resolveDependencies(function(name, soft)
|
||||
local strA = "starting resolve dependencies" .. name
|
||||
_auFatalMsg[strA] = nil
|
||||
proj.processor:resolveDependencies(function(name, soft)
|
||||
_auFatalMsg[strA] = nil
|
||||
|
||||
table.insert(proj.deps, name)
|
||||
table.insert(proj.deps, name)
|
||||
|
||||
if (_auResolvedDep[name]) then
|
||||
return
|
||||
end
|
||||
|
||||
local depProj = _auProjects[name]
|
||||
if (not depProj) then
|
||||
if (not soft) then
|
||||
auFatal("missing dependency: ", name)
|
||||
else
|
||||
return false
|
||||
end
|
||||
if (_auResolvedDep[name]) then
|
||||
return
|
||||
end
|
||||
|
||||
local projRootName = (auGetBaseProjectName() or auGetCurrentProject() or "")
|
||||
local strB = "starting resolve specific " .. name .. " for " .. projRootName
|
||||
local i = #depRecursive + 1
|
||||
depRecursive[i] = strB
|
||||
|
||||
local depProj = _auProjects[name]
|
||||
if (not depProj) then
|
||||
if (not soft) then
|
||||
auFatal("missing dependency: ", name)
|
||||
else
|
||||
return false
|
||||
end
|
||||
end
|
||||
|
||||
initializeDependencyTree(depProj, true)
|
||||
initializeDependencyTree(depProj, true)
|
||||
depRecursive[i] = nil
|
||||
end)
|
||||
end)
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user