-
Notifications
You must be signed in to change notification settings - Fork 38
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
workflows: extract workspace-root-path from a new top section from .yaml file #395
Conversation
reana_server/rest/workflows.py
Outdated
@@ -401,10 +401,15 @@ def create_workflow(user): # noqa | |||
workflow_dict["operational_options"] = validate_operational_options( | |||
workflow_engine, reana_spec_file.get("inputs", {}).get("options", {}) | |||
) | |||
workspace_root_path = reana_spec_file.get("workspace", {}).get( | |||
"workspace_root_path", None |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we have to call it workspace_root_path
? Isn't it a bit redundant having workspace
at the top level?
IMO we could simplify it and use just path
or root_path
. What do you think?
...
workspace:
path: /eos/home-s/simko/myworkflows
...
BTW, is it definite to have workspace
at the top level? I thought we were discussing it here.
PS. For get()
, you don't need to specify None
as it's the default value.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cc/ @tiborsimko @audrium
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I used workspace_root_path
as it is not the full workspace_path
, the full path would also have the workflow_uuid
. So I agree that root_path
would be a good simplification
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, +1 for workspace_path
.
Also, @marcdiazsan, for get()
, you don't need to specify None
as @mvidalgarcia mentioned
Edit: perhaps we can close this PR since all the commits are included in another one?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes this one can be closed as is included into the other PR
…aml file It passes a workspace_root_path as a parameter to rwc Closes reanahub/reana-client#545
892b0eb
to
0e508d4
Compare
Codecov Report
@@ Coverage Diff @@
## master #395 +/- ##
==========================================
+ Coverage 49.92% 49.94% +0.02%
==========================================
Files 22 22
Lines 1957 1958 +1
==========================================
+ Hits 977 978 +1
Misses 980 980
|
Closing since all the commits from this PR are included in another one |
It passes a workspace_root_path as a parameter to rwc
Closes reanahub/reana-client#545