Skip to content
Snippets Groups Projects
Commit dc3e33c0 authored by George Marchment's avatar George Marchment
Browse files

Adding filter no processes + adding pipe support for rewritting maps

parent 60a8b573
No related branches found
No related tags found
No related merge requests found
Pipeline #14641 failed with stage
in 2 minutes and 23 seconds
......@@ -137,7 +137,7 @@ class Code:
#TODO -> do the same with flatMap -> 668
for word in ["map", "flatMap"]:
for end_char in ['{', '\(']:
pattern = fr"\.\s*"+word+r"\s*"+end_char
pattern = fr"(\.|\|)\s*"+word+r"\s*"+end_char
for match in re.finditer(pattern, code):
start_map, end = match.span(0)
if(end_char=="{"):
......
......@@ -1079,7 +1079,9 @@ George Marchment, Bryan Brancotte, Marie Schmit, Frédéric Lemoine, Sarah Cohen
code = self.simplify_workflow_code()
self.rewrite_and_initialise(code, self.processes_2_remove, render_graphs=render_graphs)
if(len(self.get_processes_called())==0):
raise BioFlowInsightError("There are no process calls in the workflow. BioFlow-Insight cannot rewrite the workflow in this case.", type="Rewrite Error")
#DETERMING WHICH SUBWORKFLOWS ARE BROKEN WITH THE CLUSTER
def get_clusters_with_calls(clusters):
#Creating the clusters with calls instead of processes or subworkflows
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment