-
Notifications
You must be signed in to change notification settings - Fork 45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[feature request] add option to pass environment variables for script task #67
Comments
Thanks @tandav for sharing this suggestion. Right now the equivalent workaround is to generate the export commands yourself: @task()
def align_dna_reads_to_genome(key1, key2):
return script(f"""
export KEY_1={key1}
export KEY_2={key2}
my_command
"""
) Is your suggestion to have |
Thanks for workaround example! Lines 78 to 80 in 8df1415
It would be nice to support passing env dictionary from script() to that subrocess call. I agree that solution which requires prepending export lines is not robust.
|
Our team actually has this implemented along with a couple other changes to redun's scripting:
A limitation to just generating the If there's interest we can factor just the above changes into a PR here. Edit: For clarity, I'm part of an external team that uses redun and we maintain a private fork, always happy to contribute stuff back. |
It would be handy to pass a dict with environment variables:
The text was updated successfully, but these errors were encountered: