Skip to content

Commit

Permalink
fix pipeline run loop on joined pipelines whithout debug flag (#2777)
Browse files Browse the repository at this point in the history
* fix pipeline run loop on joined pipelines whithout debug flag

* use .keys() consistently
  • Loading branch information
tstadel committed Jul 7, 2022
1 parent 195aed9 commit d21b066
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions haystack/pipelines/base.py
Expand Up @@ -528,11 +528,12 @@ def run( # type: ignore
if queue.get(n): # concatenate inputs if it's a join node
existing_input = queue[n]
if "inputs" not in existing_input.keys():
updated_input: dict = {
"inputs": [existing_input, node_output],
"params": params,
"_debug": {**existing_input["_debug"], **node_output["_debug"]},
}
updated_input: dict = {"inputs": [existing_input, node_output], "params": params}
if "_debug" in existing_input.keys() or "_debug" in node_output.keys():
updated_input["_debug"] = {
**existing_input.get("_debug", {}),
**node_output.get("_debug", {}),
}
if query:
updated_input["query"] = query
if file_paths:
Expand Down

0 comments on commit d21b066

Please sign in to comment.