You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug(graph): literal If over an axis reopened after a Collect drops items #9917
A literal If whose selected branch iterates an axis that was reopened after a Collect gives wrong groups when the reopened collection has a different length from the original axis. An item is dropped silently and one group comes out empty. No error is raised.
Reproduction
Nodes (the test nodes are from tests/test_nodes.py):
Run it with GraphExecutionState on main (seen at ac237a1, on both schedulers).
Observed: the graph completes with three collect outputs, at paths [0] → ["t:b:a1"], [1] → ["t:b:a2"] and [2] → []. Item x never reaches t, so t:x is missing.
Expected:t:x is not lost. Either the selected branch's items are collected correctly, or the shape is rejected with UnsupportedIfIterationAxesError before anything runs, as other unsupported axis shapes are.
With condition=False the same graph is rejected with UnsupportedIfIterationAxesError once #9789 is merged.
Notes
One narrow rule would turn this into an error: allow a reopened axis only when the new Iterate reads straight from the closing Collect. That changes the result of a graph main currently completes, so it was left out of #9789 and is waiting on a maintainer decision there.
Activity