Skip to content

Commit 7b80e8f

Browse files
committed
Revert "fix: build installation dependencies before building consumers"
This reverts commit fb32ee6. We cannot build all of the installation dependencies before building some packages because there are apparent circular dependencies in some cases.
1 parent a25f7bf commit 7b80e8f

File tree

1 file changed

+5
-9
lines changed

1 file changed

+5
-9
lines changed

src/fromager/commands/build.py

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -638,17 +638,13 @@ def update_progressbar_cb(future: concurrent.futures.Future) -> None:
638638
with req_ctxvar_context(
639639
Requirement(node.canonicalized_name), node.version
640640
):
641-
# Get all dependencies. If package A needs package B to be
642-
# installed, package B should not have a build dependency on
643-
# package A. So, building the installation dependencies of a
644-
# package before we build that package should be possible,
645-
# and doing so ensures that when we mark a package as ready
646-
# to be used for building other packages, all of the
647-
# installation dependencies are also ready.
641+
# Get all build dependencies (build-system, build-backend, build-sdist)
648642
build_deps: DependencyNodeList = [
649-
edge.destination_node for edge in node.children
643+
edge.destination_node
644+
for edge in node.children
645+
if edge.req_type.is_build_requirement
650646
]
651-
# A node can be built when all of its dependencies are built
647+
# A node can be built when all of its build dependencies are built
652648
unbuilt_deps: set[str] = set(
653649
dep.key for dep in build_deps if dep.key not in built_node_keys
654650
)

0 commit comments

Comments
 (0)