sigito Posted September 20, 2020 Share Posted September 20, 2020 Hi everyone. I have a simple workflow with a script filter. The executed script reads environment variables for the run configuration. Since the Script Filter is an input object, it ignores the variables set upstream. So what I can do is set the Workflow's global variables. However, I want to duplicate the script filter to have different configuration for different keywords, and global variables won't allow me this. IS there a way to do this per script filter? Link to comment
deanishe Posted September 20, 2020 Share Posted September 20, 2020 4 hours ago, sigito said: Since the Script Filter is an input object, it ignores the variables set upstream. It doesn't. You're likely doing something wrong. 4 hours ago, sigito said: IS there a way to do this per script filter? The simplest solution would be to prefix the variables with the keyword, and have a different set of variables for each Script Filter. Link to comment
sigito Posted September 20, 2020 Author Share Posted September 20, 2020 I hope I do something wrong, but in my understanding the upstream variables are only applied if I trigger the wofrkflow with an input element before the variable element. E.g., if I put a Keyword before. But in case the variables are dangling, like on an attached screenshot, it doesn't work. Link to comment
sigito Posted September 20, 2020 Author Share Posted September 20, 2020 (edited) I think I would specify the desired variable values as options to the script filter, and parse them in the binary. That seems to be the easiest solution, which does not require hardcoding of the prefixes as you suggested. Thanks. Edited September 20, 2020 by sigito Link to comment
deanishe Posted September 20, 2020 Share Posted September 20, 2020 2 hours ago, sigito said: the upstream variables are only applied if I trigger the wofrkflow with an input element before the variable element. E.g., if I put a Keyword before. Yes. If your entry point is a Script Filter, then anything upstream of that doesn't get run. 2 hours ago, sigito said: I think I would specify the desired variable values as options to the script filter If they don't need to be edited by the user, that's also perfectly fine. Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now