-
Notifications
You must be signed in to change notification settings - Fork 7
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
Make it possible to cancel an in-progress simulation #1032
Conversation
This will be so useful! Not something we need to do in this PR but wonder if we should have a visual indicator on the timeline for when a sim was canceled so that it's obvious that the lack of data in certain places is due to sim cancelation and not some sort of gap? Though perhaps if you cancel a sim you don't really care about sim results? If we decide to do anything about this then it should also play into whatever we do for streaming sim results.. |
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.
This is awesome! My one concern is choice of icon to cancel or maybe its placement. To me it looks like it's a "close" button and clicking it would get rid of the current simulation from the UI altogether. Maybe if you hover over "in progress", it shows "cancel"?
Ooooh. My bad. I still think that the icon might be misleading, but I'll let you @mattdailis decide whether or not that gets updated in this PR or another effort or if it's worth updating at all. |
One thing I'm noticing which could just be how the backend works now is that if i queue up a bunch of simulations (past the number of available workers) the pending sims will stay pending until a worker completes a sim and then all pending sims except for the latest one will be marked as failed. I'm assuming this is somewhat similar to the old behavior where pending sims that were outdated would be auto canceled? In any case, seems odd to mark them as failed in the UI here, wondering how we should handle this? |
Another issue that could be in a separate PR is that sims are cancelable during plan snapshot preview |
946002b
to
1a6c915
Compare
1a6c915
to
62daa74
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.
Other than the feedback that @AaronPlave left, I think this works great! Thank you!
@mattdailis also if you want to disable the button if it's in plan preview, there's a |
90a29a4
to
f145d7e
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.
Just left a small pedantic CSS comment. Feel free to ignore it if you don't think it's worth updating. This looks good to me otherwise! Great work!
f145d7e
to
810a194
Compare
* Make it possible to cancel an in-progress simulation * Handle simulations canceled after finishing * Update stellar and tweak button css * Fix package.json lint error * Disable cancel buttons when plan is read only
* Make it possible to cancel an in-progress simulation * Handle simulations canceled after finishing * Update stellar and tweak button css * Fix package.json lint error * Disable cancel buttons when plan is read only
We previously implemented the ability to cancel pending simulations. As of a week or two ago, the backend now supports canceling in-progress simulations. This PR moves around a few if statements in the UI code to:
Canceled
ifsimulationDataset.canceled
reason
fieldScreen.Recording.2023-11-29.at.3.58.07.PM.mov