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

add scripting utils #214

Merged
merged 13 commits into from
Jun 23, 2023
Merged

add scripting utils #214

merged 13 commits into from
Jun 23, 2023

Conversation

juliettelavoie
Copy link
Contributor

@juliettelavoie juliettelavoie commented Jun 20, 2023

Pull Request Checklist:

  • This PR addresses an already opened issue (for bug fixes / features)
    • This PR fixes #xyz
  • (If applicable) Documentation has been added / updated (for bug fixes / features).
  • (If applicable) Tests have been added.
  • This PR does not seem to break the templates.
  • HISTORY.rst has been updated (with summary of main changes).
    • Link to issue (:issue:number) and pull request (:pull:number) has been added.

What kind of change does this PR introduce?

  • save_and_update: nothing new, just putting things that exists all together so that I only have one line at the end of each tasks.
    ** I removed the "move" part of that function, because we want to encourage Ouranos users to write everything in one place and than use move_and_delete.
  • move_and_delete: In a workflow, when a simulation is done, you can save what you want to keep (final, maybe regridded and log file) and delete the workdir.
  • added catutils to the API for the docs

Does this PR introduce a breaking change?

no

Other information:

  • how do we do tests for io stuff ?
  • I am thinking of using these function in template 1, but I am not sure. It might be better to see that save and update are different functions when you are learning xscen? Is move_and_delete too advanced for basic workflow ?

@juliettelavoie juliettelavoie requested a review from aulemahal June 22, 2023 17:14
Copy link
Collaborator

@aulemahal aulemahal left a comment

Choose a reason for hiding this comment

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

Looks good.

I'm also not sure who this can be integrated in the test suite. You could generate a file and move it around, checking that the catalog is updated. It would be a very shallow test...

@juliettelavoie juliettelavoie merged commit 0fb765b into main Jun 23, 2023
@juliettelavoie juliettelavoie deleted the add-utils branch June 23, 2023 15:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants