Skip to content

Commit

Permalink
Reimplement filter to be more like the original
Browse files Browse the repository at this point in the history
Signed-off-by: Deepyaman Datta <deepyaman.datta@utexas.edu>
  • Loading branch information
deepyaman committed Oct 10, 2023
1 parent 2a41680 commit 26ba1e5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions kedro/pipeline/pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ def __init__(
for output in node.outputs:
self._nodes_by_output[_strip_transcoding(output)] = node

self._nodes = nodes
self._nodes: list[Node] = nodes
self._topo_sorted_nodes = _topologically_sorted(self.node_dependencies)

def __repr__(self): # pragma: no cover
Expand Down Expand Up @@ -760,7 +760,7 @@ def filter( # noqa: too-many-arguments
# would give different outcomes depending on the order of filter methods:
# only_nodes and then from_inputs would give node1, while only_nodes and then
# from_inputs would give node1 and node3.
filtered_pipeline = self
filtered_pipeline = Pipeline(self._nodes)
for subset_pipeline in subset_pipelines:
filtered_pipeline &= subset_pipeline

Expand Down

0 comments on commit 26ba1e5

Please sign in to comment.