-
Notifications
You must be signed in to change notification settings - Fork 26
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
⚗️ Reject saving project while pipeline is running #2797
⚗️ Reject saving project while pipeline is running #2797
Conversation
Codecov Report
@@ Coverage Diff @@
## master #2797 +/- ##
========================================
- Coverage 78.8% 78.8% -0.1%
========================================
Files 670 670
Lines 27200 27230 +30
Branches 2669 2677 +8
========================================
+ Hits 21458 21475 +17
- Misses 4985 4999 +14
+ Partials 757 756 -1
Flags with carried forward coverage won't be shown. Click here to find out more.
|
services/web/server/src/simcore_service_webserver/projects/projects_handlers.py
Show resolved
Hide resolved
services/director-v2/src/simcore_service_director_v2/api/routes/computations.py
Outdated
Show resolved
Hide resolved
services/web/server/src/simcore_service_webserver/director_v2_core.py
Outdated
Show resolved
Hide resolved
This reverts commit 657d541.
3cd31f1
to
5354be2
Compare
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.
looking good.
services/web/server/src/simcore_service_webserver/projects/projects_utils.py
Show resolved
Hide resolved
# TODO: how to ensure this list of "links types" is up-to-date!?? | ||
# These types represent links that node-ports need to handle | ||
if isinstance(input_value, PortLink, DownloadLink, BaseFileLink): |
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.
Maybe this should be provided by some utility function in nodeports and have some tests which makes sure the list is up to date. But it will still not be prefect.
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.
the tests are fine but I would rather have something closer to that line ... I added some assertion
s next to t but the check is for the moment limited.
What do these changes do?
Changes in node inputs (e.g. changing links or values) are not allowed to be saved while the pipelines are running.
NOTE: This PR complements the front-end PR #2795 that will gray out the workbench while pipelines run
Details
This is a temporary measure that we adopt in order to avoid an unstable state that occurs when a study is running a pipeline and the links between (newly added) nodes do not work anymore. In addition, this scenario has recently appeared more frequently due to other problems with the scheduler that would leave pipelines running forever.
The underline problem requires some more detail analysis of the underline
nodeports
library that could take a bit longer to fulfill. When that happens this limitation will be removed.We agreed that the webserver will respond with 409: The request could not be completed due to a conflict with the current state of the target resource (i.e. pipeline is running). This code is used in situations where the user might be able to resolve the conflict and resubmit the request (front-end will show a pop-up with message below).
@odeimaiz you can instead use the message in the error response
Related issue/s
How to test
Checklist
make openapi-specs
,git commit ...
and thenmake version-*
)cd packages/postgres-database
,make setup-commit
,sc-pg review -m "my changes"