Skip to content

E3-320: Determine valid build order from specification

Simon Rose requested to merge e3_320 into specification

Given:

  • a collection of modules and tags

We want to:

  • Determine a valid build order based on ensuring that if A depends on B then B is built before A.

Note that there are a few quirks: we just take the full set of dependencies over all modules. So it is theoretically possible that this introduces some level of inconsistency (imagine that version 1 of module A depends on version 1 of module B, but version 2 of module B depends on version 2 of module A). There is a check added (check_dag) that will fail if this happens, which we should absolutely investigate.

This runs much as before:

handler = SpecificationHandler(Specification.from_yaml(env_file), GITLAB_TOKEN)

print(handler.sorted_order)

which will print the sorted order.

Edited by Simon Rose

Merge request reports