What happened?
The function creates extra unnecessary Usages when a regex pattern is used in a rule step the second step.
How can we reproduce it?
Use a rule sequence such as:
- first
- second
- third*
The regex patter will never match a literal observed resource, so the function has to scan the entire list of rules for resources to match, instead of just looking at the previous rule. This causes Usages to be created for the "third*->first" resources in addition to the second->first and third*->second.
The immediate fix is to only do deletion dependency processing on the rule before the current rule, but I suspect this code really needs to be refactored to make it more stable.
What environment did it happen in?
Function version: 0.5.0
What happened?
The function creates extra unnecessary
Usageswhen a regex pattern is used in a rule step the second step.How can we reproduce it?
Use a rule sequence such as:
The regex patter will never match a literal observed resource, so the function has to scan the entire list of rules for resources to match, instead of just looking at the previous rule. This causes
Usagesto be created for the "third*->first" resources in addition to the second->first and third*->second.The immediate fix is to only do deletion dependency processing on the rule before the current rule, but I suspect this code really needs to be refactored to make it more stable.
What environment did it happen in?
Function version: 0.5.0