-
Notifications
You must be signed in to change notification settings - Fork 1
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
fix: check plan.IsTerminated on IsPlanRunning #432
Conversation
Signed-off-by: ThibaultFy <thibault.fouqueray@gmail.com>
Signed-off-by: ThibaultFy <thibault.fouqueray@gmail.com>
/e2e --tests sdk,mnist |
Signed-off-by: ThibaultFy <thibault.fouqueray@gmail.com>
@@ -703,10 +703,14 @@ func TestIsPlanRunning(t *testing.T) { | |||
require.Nil(t, err) | |||
|
|||
resp = appClient.IsPlanRunning("cp2") | |||
require.True(t, resp.IsRunning) | |||
require.False(t, resp.IsRunning) |
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.
@guilhem-barthes looks like that we where testing this use case and expecting it to be Running
even after canceling it... We agree that we want it to be not running
if canceled right ?
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.
Sounds about right
Signed-off-by: ThibaultFy <thibault.fouqueray@gmail.com>
lib/service/computeplan.go
Outdated
if plan.IsTerminated() { | ||
return false, err | ||
} else { | ||
return s.GetComputePlanDBAL().IsPlanRunning(key) |
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.
Architecture wise, I feel like IsPlanRunning
should be renamed
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.
On service side or dbal ?
Signed-off-by: ThibaultFy <thibault.fouqueray@gmail.com>
/e2e --tests sdk,mnist |
End to end tests: ✔️ SUCCESS You rock! |
Signed-off-by: ThibaultFy <thibault.fouqueray@gmail.com>
Description
check is plan.terminated when calling IsPlanRunning instead of changing the status of the task, cause it does not change the behaviour of
IsPlanRunning
(checked before changing task status).This PR revert a part of #427 and closes FL-1593