Introduced osenv to handle filter values dependent on the same (probably unneeded with the new allow action method)
This commit is contained in:
@@ -1,3 +1,7 @@
|
||||
import os
|
||||
|
||||
## dictionary for action resolution is "RESOLVED"
|
||||
|
||||
def applyConditions(definition, dictionary, outputs):
|
||||
if hasattr(definition, "filters"):
|
||||
|
||||
@@ -5,8 +9,11 @@ def applyConditions(definition, dictionary, outputs):
|
||||
try:
|
||||
filtervalue = filter["filtervalue"]
|
||||
if isinstance(filter["filtervalue"], dict):
|
||||
if "outputs" in filtervalue:
|
||||
filtervalue = outputs.get(filtervalue["outputs"])
|
||||
elif "osenv" in filtervalue:
|
||||
filtervalue = os.environ.get(filtervalue["osenv"])
|
||||
|
||||
filtervalue = outputs.get(filtervalue["outputs"])
|
||||
if filtervalue is None:
|
||||
continue
|
||||
|
||||
|
||||
Reference in New Issue
Block a user