Skip to content
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

renku run fails with external files #2796

Closed
m-alisafaee opened this issue Mar 31, 2022 · 0 comments · Fixed by #2817
Closed

renku run fails with external files #2796

m-alisafaee opened this issue Mar 31, 2022 · 0 comments · Fixed by #2817
Assignees
Labels

Comments

@m-alisafaee
Copy link
Contributor

Describe the bug
When external files are used in reknu run an exception is raised.

To Reproduce
Steps to reproduce the behavior:

  1. renku dataset add --create my-data --external /path/to/file
  2. renku run cat data/my-data/file > output3.

Expected behavior
Running with external file should be the same as running with files in the project.

Screenshots and/or execution output

Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.7/bin/renku", line 8, in <module>
    sys.exit(cli())
  File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/click/core.py", line 1137, in __call__
    return self.main(*args, **kwargs)
  File "/Users/Me/Documents/Workspace.noindex/sdsc/code/renku-python/renku/cli/exception_handler.py", line 128, in main
    result = super().main(*args, **kwargs)
  File "/Users/Me/Documents/Workspace.noindex/sdsc/code/renku-python/renku/cli/exception_handler.py", line 92, in main
    return super().main(*args, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/click/core.py", line 1062, in main
    rv = self.invoke(ctx)
  File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/click/core.py", line 1668, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/click/core.py", line 1404, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/click/core.py", line 763, in invoke
    return __callback(*args, **kwargs)
  File "/Users/Me/Documents/Workspace.noindex/sdsc/code/renku-python/renku/cli/run.py", line 321, in run
    command_line=command_line,
  File "/Users/Me/Documents/Workspace.noindex/sdsc/code/renku-python/renku/core/management/command_builder/command.py", line 283, in execute
    output = context["click_context"].invoke(self._operation, *args, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/click/core.py", line 763, in invoke
    return __callback(*args, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/inject/__init__.py", line 342, in injection_wrapper
    return sync_func(*args, **kwargs)
  File "/Users/Me/Documents/Workspace.noindex/sdsc/code/renku-python/renku/core/commands/run.py", line 157, in _run_command
    **{name: os.path.relpath(path, working_dir) for name, path in mapped_std.items()},
  File "/Users/Me/Documents/Workspace.noindex/sdsc/code/renku-python/renku/core/management/workflow/plan_factory.py", line 124, in __init__
    self.add_inputs_and_parameters(*detected_arguments)
  File "/Users/Me/Documents/Workspace.noindex/sdsc/code/renku-python/renku/core/management/workflow/plan_factory.py", line 240, in add_inputs_and_parameters
    default_value=self._path_relative_to_root(default.path),
  File "/Users/Me/Documents/Workspace.noindex/sdsc/code/renku-python/renku/core/management/workflow/plan_factory.py", line 646, in _path_relative_to_root
    return str((self.directory / path).resolve().relative_to(self.working_dir))
  File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/pathlib.py", line 900, in relative_to
    .format(str(self), str(formatted)))
ValueError: '/Users/Me/Documents/Workspace.noindex/sdsc/data/LEGO.csv' does not start with '/private/tmp/a'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant