Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

drop support for interpreting graphs with more than one head #75

Closed
r0ller opened this issue Jan 23, 2024 · 0 comments
Closed

drop support for interpreting graphs with more than one head #75

r0ller opened this issue Jan 23, 2024 · 0 comments

Comments

@r0ller
Copy link
Owner

r0ller commented Jan 23, 2024

There is some code in interpreter::find_dependencies_for_functor() (the one for non-optional deps) that contains code that was meant to support graphs with more than one head. A minimal example for that is when A and B nodes are head (main) nodes and C is a dependency of both but A and B are not related to each other at all. The course of development did not follow that idea and now it poses a problem for nodes with a functor having more than one d_key. Let's extend the previous example to a diamond shape where A is the root, B and C are dependencies of A but B is a dependency of A's functor with d_key 1 and C is a dependency of A's functor with d_key 2. D is a dependency of B and C. When this function processes the dependencies of D (if any), in the end it'll check the node links of D and finds either B or C depending on which direction is processed first. So find_dependencies_for_node() will be called for the node D, registering B or C as it's main node, connecting the nodes in a way like A->B->D->C (or A->C->D->B) which is wrong since it should either be A->B->D or A->C->D.

r0ller added a commit that referenced this issue Jan 31, 2024
r0ller added a commit that referenced this issue Jan 31, 2024
@r0ller r0ller closed this as completed Feb 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant