Skip to content
Snippets Groups Projects
Commit be3f1773 authored by Petter Källström's avatar Petter Källström
Browse files

Update signal_flow_graph.SFG.find_by_type_name. Now it actually checks the...

Update signal_flow_graph.SFG.find_by_type_name. Now it actually checks the type name, and not the _graph_id. Safer (if user changed the graph_id), and no need for regex.
parent b874af0a
No related tags found
1 merge request!443Update signal_flow_graph.SFG.find_by_type_name. Now it actually checks the...
Pipeline #127829 failed
......@@ -549,10 +549,8 @@ class SFG(AbstractOperation):
type_name : TypeName
The TypeName of the desired components.
"""
reg = f"{type_name}[0-9]+"
p = re.compile(reg)
components = [
val for key, val in self._components_by_id.items() if p.match(key)
com for com in self._components_dfs_order if com.type_name() == type_name
]
return components
......
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