Skip to content

Commit

Permalink
Disallow wildcard matching for sos_step #983
Browse files Browse the repository at this point in the history
  • Loading branch information
Bo Peng committed Jun 15, 2018
1 parent f746725 commit 88cfa3d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/sos/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ def step_name(self, alias: bool = False) -> str:
def match(self, step_name: str) -> bool:
# if this step provides name...
for name, index, _ in self.names:
if step_name == name or step_name == f'{name}_{0 if index is None else int(index)}':
if (step_name == name and self.index is None) or step_name == f'{name}_{0 if index is None else int(index)}':
return True
return False

Expand Down

0 comments on commit 88cfa3d

Please sign in to comment.