MCPcopy Create free account
hub / github.com/coder/coder / GetUnmetDependencies

Method GetUnmetDependencies

agent/unit/manager.go:274–285  ·  view source on GitHub ↗

GetUnmetDependencies returns a list of unsatisfied dependencies for a unit.

(unit ID)

Source from the content-addressed store, hash-verified

272
273// GetUnmetDependencies returns a list of unsatisfied dependencies for a unit.
274func (m *Manager) GetUnmetDependencies(unit ID) ([]Dependency, error) {
275 allDependencies, err := m.GetAllDependencies(unit)
276 if err != nil {
277 return nil, err
278 }
279
280 var unmetDependencies []Dependency = slice.Filter(allDependencies, func(dependency Dependency) bool {
281 return !dependency.IsSatisfied
282 })
283
284 return unmetDependencies, nil
285}
286
287// ExportDOT exports the dependency graph to DOT format for visualization.
288func (m *Manager) ExportDOT(name string) (string, error) {

Callers 2

Calls 2

GetAllDependenciesMethod · 0.95
FilterFunction · 0.92

Tested by 2