8000 For script tasks, `tempdir=True` with remote executor produces an error · Issue #20 · insitro/redun · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
For script tasks, tempdir=True with remote executor produces an error #20
Open
@spitz-dan-l

Description

@spitz-dan-l

Hi there! The following task:

@task()
def main():
    return script('echo HELLO', tempdir=True, executor='batch')

Produces this output:

Traceback (most recent call last):
  File "***/bin/redun", line 11, in <module>
    client.execute()
  File "***/lib/python3.7/site-packages/redun/cli.py", line 1021, in execute
    return args.func(args, extra_args, argv)
  File "***/lib/python3.7/site-packages/redun/cli.py", line 1558, in run_command
    tags=tags,
  File "***/lib/python3.7/site-packages/redun/scheduler.py", line 831, in run
    raise result.value
redun.scripting.ScriptError: Last line: ./.task_command: line 3: cd: /tmp/tmpkt20ugrt.tempdir: No such file or directory

It looks like the design of script() is to create the temp dir when calling script(), but execute the command in a downstream task. Since the downstream task is run remotely, the tempdir won't exist.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0