-
Notifications
You must be signed in to change notification settings - Fork 202
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
Archive easyblocks along with easyconfig #2653
Conversation
Fix broken check for generic easyblock
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ocaisa A bit of logging wouldn't hurt here imho...
Be more strict on where to stop easyblock dumping
@@ -2859,7 +2862,6 @@ def build_and_install_one(ecdict, init_env): | |||
errormsg = "build failed (first %d chars): %s" % (first_n, err.msg[:first_n]) | |||
_log.warning(errormsg) | |||
result = False | |||
app.close_log() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Logging was being shut down too early, meaning all logging below this was lost
@boegel Cleaned up and good to go now |
@@ -2982,6 +2978,39 @@ def build_and_install_one(ecdict, init_env): | |||
return (success, application_log, errormsg) | |||
|
|||
|
|||
def reproduce_build(app, reprod_dir_root): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@boegel I need some help with how to unit test this, not sure what's required to get a proper app
instance
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
...or perhaps what is already tested is good enough?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ocaisa Once you have a parsed easyconfig (for example for toy-0.0.eb
in the tests, you can just create an easyblock instance like MyEasyBlock(parsed_easyconfig)
(e.g. Toy(toy_ec)
).
But I guess there's no strong need to test this function in isolation, since it's always being called. Just make sure whatever it produces it being checked, which you're already doing I think.
@ocaisa I'll check why @boegelbot isn't picking up on this, but there's a failing test:
|
To address easybuilders/easybuild-easyblocks#1574 , should I be doing the reproducability dump before |
@boegel After a quick test, the approach in the last comment looks like it would solve easybuilders/easybuild-easyblocks#1574 but I would like your opinion before I implement. |
…d then copy it over after success
Ok, I've implemented the move. This covers the case where modifications come from the command line (or configuration) and dependency resolution but doesn't cover what hooks might do. I think I'd also like to archive those but I don't know how to access them. |
Urgh, I already see a problem with the hook example https://easybuild.readthedocs.io/en/latest/Hooks.html?highlight=hooks#example-hook-to-inject-a-custom-patch-file |
I've reverted this back to simply also dumping the used easyblocks. Fixing the deeper problems of this approach (as in easybuilders/easybuild-easyblocks#1574) is for another PR. |
lgtm, thanks @ocaisa! |
Fixes #2633