(task, taskMap)
| 153 | return map; |
| 154 | } |
| 155 | |
| 156 | function dependencyStatus(task, taskMap) { |
| 157 | const blockers = []; |
| 158 | for (const dep of task.deps || []) { |
| 159 | const target = taskMap.get(String(dep)); |
| 160 | if (!target) { |
| 161 | blockers.push({ dep: String(dep), status: 'missing', reason: 'dependency is not in the work queue' }); |
| 162 | continue; |
| 163 | } |
| 164 | |
| 165 | const status = normalizeStatus(target.status); |
| 166 | if (!SUCCESS_STATUSES.has(status)) { |
| 167 | blockers.push({ dep: String(dep), status, reason: 'dependency is not complete' }); |
| 168 | } |
| 169 | } |
| 170 | return blockers; |
| 171 | } |
| 172 | |
| 173 | function isRunnable(task, taskMap = null) { |
no test coverage detected