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

Show delete run-path dialog only for non-empty iter #7860

Closed
wants to merge 1 commit into from

Conversation

dafeda
Copy link
Contributor

@dafeda dafeda commented May 8, 2024

Resolves: #7633

  • PR title captures the intent of the changes, and is fitting for release notes.
  • Added appropriate release note label
  • Commit history is consistent and clean, in line with the contribution guidelines.
  • Make sure tests pass locally (after every commit!)

When applicable

  • When there are user facing changes: Updated documentation
  • New behavior or changes to existing untested code: Ensured that unit tests are added (See Ground Rules).
  • Large PR: Prepare changes in small commits for more convenient review
  • Bug fix: Add regression test for the bug
  • Bug fix: Create Backport PR to latest release

@dafeda dafeda self-assigned this May 8, 2024
@codecov-commenter
Copy link

codecov-commenter commented May 8, 2024

Codecov Report

Attention: Patch coverage is 93.33333% with 1 lines in your changes are missing coverage. Please review.

Project coverage is 85.38%. Comparing base (7cd3f71) to head (2d9e604).

Files Patch % Lines
src/ert/gui/simulation/simulation_panel.py 87.50% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #7860   +/-   ##
=======================================
  Coverage   85.38%   85.38%           
=======================================
  Files         381      381           
  Lines       23602    23611    +9     
  Branches      892      883    -9     
=======================================
+ Hits        20152    20161    +9     
+ Misses       3341     3336    -5     
- Partials      109      114    +5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dafeda dafeda added the release-notes:bug-fix Automatically categorise as bug fix in release notes label May 14, 2024
@dafeda dafeda changed the title Delete runpath Show delete run-path dialog only for non-empty iter May 14, 2024
@@ -613,6 +613,15 @@ def check_if_runpath_exists(self) -> bool:
"""
return any(Path(run_path).exists() for run_path in self.paths)

def check_if_runpath_contains_data(self, iteration: int) -> bool:
target_folder = f"iter-{iteration}"
Copy link
Collaborator

Choose a reason for hiding this comment

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

There is no requirement to have iter in the runpath, and for example in prediction runs it is not used, so changing poly.ert to: RUNPATH poly_out/realization-<IENS>/<PRED_DIR> is valid.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah, that makes sense. Need to rethink this then.

def check_if_runpath_contains_data(self, iteration: int) -> bool:
target_folder = f"iter-{iteration}"

for run_path in self.paths:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Think perhaps this is the root cause of the problems, self.paths should only return what is actually going to be run in, but suspect there is a bug there.

@oyvindeide
Copy link
Collaborator

Suggest removing: start_iteration from SimulationArguments (as it is always 0), and letting the run model decide what the value is, for most it will be 0, but for ES-MDA it might be something else if it is a restart run.

@dafeda
Copy link
Contributor Author

dafeda commented May 22, 2024

Solved by: #7940

@dafeda dafeda closed this May 22, 2024
@dafeda dafeda deleted the delete-runpath branch May 22, 2024 06:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-notes:bug-fix Automatically categorise as bug fix in release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

False positive on running in existing runpath
3 participants