-
Notifications
You must be signed in to change notification settings - Fork 207
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
Support component customization of case.setup clean #4167
Comments
I supported this design on Slack, and still feel like it would be reasonable, but I also just realized that this need is at least somewhat similar to the optional get_user_nl_list function that is now supported in components' buildnml file - see #4058 . One reason I went with the design of putting this function in buildnml rather than in its own script is that I wanted to share some functionality between this function and other aspects of buildnml. This does not allow get_user_nl_list to be called as a subprocess (it requires it to be called as a python function), but that felt okay to me. Longer-term, I think it would be great if we could move towards accessing all of these functions from a real python package, leveraging the changes that @mnlevy1981 recently made. |
@billsacks If I understand you correctly instead of a new script there would be an optional new function in the buildnml script. This would be invoked by case.setup --clean if it exists and it would not be required to exist in every component. @jgfouca I think that this is more like what you were originally considering and is probably less involved than creating a new setup script. I think that it would be fine to pursue this solution instead. I think that we would need a standard name - cleannml is probably good. |
@jedwards4b yes, exactly. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
@jgfouca are you still planning to do this? |
@jedwards4b , yes |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
I have a usecase for one of our atm components (SCREAM) that I'm not sure how to handle. The buildnml for this component makes some YAML files that are processed when the component is run. buildnml is coded to not overwrite these files if they already exist in the case in order to preserve local modifications. What I want is for these files to be removed when the user does a ./case.setup --clean and regenerated when the user does a ./case.setup --reset . What I am seeing is that CIME has no way to notify a component that a clean/reset has been requested.
Some slack discussion has us in tentative agreement that we could add support for a cleaner script in components that
./case.setup --clean
would look for and invoke if found.The text was updated successfully, but these errors were encountered: