... |
... |
@@ -434,9 +434,9 @@ class Loader(): |
434
|
434
|
|
435
|
435
|
treated_elements = []
|
436
|
436
|
|
437
|
|
- print("-" * 60)
|
|
437
|
+ # print("-" * 60)
|
438
|
438
|
while all_elements:
|
439
|
|
- print([e.name for e in all_elements])
|
|
439
|
+ # print([e.name for e in all_elements])
|
440
|
440
|
current = all_elements.popleft()
|
441
|
441
|
|
442
|
442
|
if current.visited:
|
... |
... |
@@ -444,11 +444,15 @@ class Loader(): |
444
|
444
|
|
445
|
445
|
missing_deps = [
|
446
|
446
|
dep.element
|
447
|
|
- for dep in sorted(filter(not_visited, current.dependencies), key=cmp_to_key(compare_unprocessed))
|
|
447
|
+ for dep in sorted(filter(not_visited, current.dependencies), key=cmp_to_key(compare_unprocessed), reverse=True)
|
448
|
448
|
]
|
449
|
449
|
|
450
|
450
|
if missing_deps:
|
451
|
|
- print(current.name, "bumped")
|
|
451
|
+ for entry in missing_deps:
|
|
452
|
+ all_elements.remove(entry)
|
|
453
|
+
|
|
454
|
+ # print(current.name, "bumped")
|
|
455
|
+ # print("Adding", [d.name for d in missing_deps])
|
452
|
456
|
all_elements.appendleft(current)
|
453
|
457
|
all_elements.extendleft(missing_deps)
|
454
|
458
|
continue
|
... |
... |
@@ -477,13 +481,17 @@ class Loader(): |
477
|
481
|
if dep.dep_type != Symbol.BUILD:
|
478
|
482
|
meta_element.dependencies.append(dependency)
|
479
|
483
|
|
480
|
|
- print("------------------")
|
|
484
|
+ # print("------------------")
|
481
|
485
|
for element in self._meta_elements.values():
|
482
|
486
|
element.build_dependencies.sort(key=attrgetter("index"))
|
483
|
487
|
element.dependencies.sort(key=attrgetter("index"))
|
484
|
|
- print("element:", element.name, [e.name for e in element.build_dependencies], [e.name for e in element.dependencies])
|
485
|
|
- print("####################")
|
|
488
|
+ # print("element:", element.name, [e.name for e in element.build_dependencies], [e.name for e in element.dependencies])
|
|
489
|
+ # print("####################")
|
486
|
490
|
|
|
491
|
+ # print("*" * 50)
|
|
492
|
+ # for element in sorted(self._meta_elements.values(), key=attrgetter("index")):
|
|
493
|
+ # print(element.name)
|
|
494
|
+ # print("*" * 50)
|
487
|
495
|
|
488
|
496
|
|
489
|
497
|
|