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

fix: don't ignore failed exps #9693

Merged
merged 9 commits into from
Aug 13, 2024
Merged

fix: don't ignore failed exps #9693

merged 9 commits into from
Aug 13, 2024

Conversation

carolinaecalderon
Copy link
Contributor

@carolinaecalderon carolinaecalderon commented Jul 22, 2024

Ticket

RM-70

Description

If a searcher completes but the experiment fails in shutdown, the experiment should end in failure. Thus, if an experiment is cancelled, a trial failure should trump the CANCELLED state = the experiment should be marked as FAILED.

Test Plan

See new e2e test, and edited e2e tests. No manual testing needed.

Checklist

  • Changes have been manually QA'd
  • New features have been approved by the corresponding PM
  • User-facing API changes have the "User-facing API Change" label
  • Release notes have been added as a separate file under docs/release-notes/
    See Release Note for details.
  • Licenses have been included for new code which was copied and/or modified from any external code

@cla-bot cla-bot bot added the cla-signed label Jul 22, 2024
Copy link

netlify bot commented Jul 22, 2024

Deploy Preview for determined-ui canceled.

Name Link
🔨 Latest commit 0db6296
🔍 Latest deploy log https://app.netlify.com/sites/determined-ui/deploys/66bb74c5e6b4d60008b69963

Copy link

codecov bot commented Jul 22, 2024

Codecov Report

Attention: Patch coverage is 20.00000% with 4 lines in your changes missing coverage. Please review.

Project coverage is 54.27%. Comparing base (79ffa52) to head (0db6296).
Report is 1 commits behind head on main.

Files Patch % Lines
master/internal/experiment.go 20.00% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #9693      +/-   ##
==========================================
- Coverage   54.29%   54.27%   -0.03%     
==========================================
  Files        1261     1261              
  Lines      155642   155646       +4     
  Branches     3536     3536              
==========================================
- Hits        84510    84473      -37     
- Misses      70994    71035      +41     
  Partials      138      138              
Flag Coverage Δ
backend 44.90% <20.00%> (-0.08%) ⬇️
harness 72.61% <ø> (ø)
web 53.71% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
master/internal/experiment.go 30.21% <20.00%> (-0.18%) ⬇️

... and 7 files with indirect coverage changes

@determined-ci determined-ci requested a review from a team July 30, 2024 16:41
@determined-ci determined-ci added the documentation Improvements or additions to documentation label Jul 30, 2024
Copy link
Contributor

@NicholasBlaskey NicholasBlaskey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@carolinaecalderon carolinaecalderon force-pushed the carolinac/rm-70 branch 2 times, most recently from 9bd7b15 to 0eb5e35 Compare August 1, 2024 14:23
@carolinaecalderon carolinaecalderon marked this pull request as draft August 1, 2024 17:29
@carolinaecalderon carolinaecalderon marked this pull request as ready for review August 12, 2024 20:32
@@ -1135,3 +1137,12 @@ func (e *internalExperiment) setRP(resourcePool string) error {

return nil
}

func notASearcherShutdown(ops []searcher.Operation) bool {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this function name made it harder to understand the intent of the function and how it was used.

What if the function was named something like allSearcherShutdown(...) and it returned false as soon as it found an operation that wasn't a shutdown error (and otherwise true)?

Then the if statement above would look like

if _, ok := model.StoppingStates[e.State]; ok && !allSearcherShutdown(ops) {

Just my 2cents. Feel free to ignore if this sounds more confusing to you.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah this is what I was afraid of, thanks for the feedback

Copy link
Contributor

@kkunapuli kkunapuli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. I found the name of notASearcherShutdown confusing but it's not a blocker.

Copy link
Member

@tara-det-ai tara-det-ai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added suggestion

@determined-ci determined-ci requested a review from a team August 13, 2024 14:25
Copy link
Contributor

@azhou-determined azhou-determined left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@carolinaecalderon carolinaecalderon merged commit e357849 into main Aug 13, 2024
119 of 122 checks passed
@carolinaecalderon carolinaecalderon deleted the carolinac/rm-70 branch August 13, 2024 19:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla-signed documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants