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

Comp scripts include copying to general binary folder #907

Open
JanStreffing opened this issue Mar 2, 2023 · 3 comments
Open

Comp scripts include copying to general binary folder #907

JanStreffing opened this issue Mar 2, 2023 · 3 comments

Comments

@JanStreffing
Copy link
Contributor

When executing a comp script while debugging the compiling of a coupled model setup, the user can fall into a trap. Compiling with the comp-${model}.sh script does not copy the created binary into the coupled setup bin folder. Thus the user may repeatedly use old binaries. I've heard this issue occuring twice recently for @hegish and @tsemmler05. I also stumbled over this in the past.

The solution would be, to ensure that the copy command is part of the comp script, rather than a separate os.copy command in python.

@mandresm
Copy link
Contributor

mandresm commented Mar 3, 2023

Thanks for the suggestion. I think it's a good idea, however, I am not sure if there will be a conflict with other functions of the esm_master. Consequently, we need to look at this carefully, meaning we can only tackle this in a couple of weeks. For the time being (and in general as a recommendation) I suggest that everyone uses esm_master comp-<setup>-<version>/<model> -k. That was the way it was designed to be used. The -k keeps all the comp files in the current folder so one can look around.

I'll put it into our project management tool, as a small feature to work on, but please feel to remind us about it later on if we have not solved in a few weeks.

@JanStreffing
Copy link
Contributor Author

I suggest that everyone uses esm_master comp-<setup>-<version>/<model> -k. That was the way it was designed to be used. The -k keeps all the comp files in the current folder so one can look around.

Hey Miguel, thank you for picking this up. Can you elaborate on this sentence? Current folder as in model_codes? How does this relate to the issue of binaries not being copied back to the setup/bin dir?

@mandresm
Copy link
Contributor

mandresm commented Mar 3, 2023

Yes, current folder as model_codes or whatever folder you where using as a base to clone the model's/couple setup's repo.

The -k flag relates to the issue of the binaries not copied to setup/bin dir because I assume that people wanting this fix are people that are debugging or looking into the details of the compilation and therefore want to keep the comp files around. However, I see that I have forgotten about something important, this people don't want to use esm_master comp-<setup>-<version>/<model> because that would overwrite the comp file and what they are trying to do is to edit this comp file manually and then run the compilation... so I see even better the problem now.

In summary: forget about my recommendation for these type of users. For now they need to copy the binaries manually, or add that line manually to their compilation scripts.

Albedo and other projects are consuming quite some time, apologies to @tsemmler05 and @hegish, but we cannot fix this right away.

@mandresm mandresm changed the title comp script does not overwrite binary in coupled model bin/ dir Comp scripts include copying to general binary folder Mar 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants