Bug fix : issues in md5 and checksum commands#503
Conversation
| package.do_stage() | ||
| with package.stage as stage: | ||
| stage.delete_on_exit = False | ||
| package.do_stage() |
There was a problem hiding this comment.
@tgamblin The three lines here went in accidentally. They are not wrong, but I didn't mean to put them in before we agreed whether or not it is better to remove the explicit call to stage.create() in Package._make_stage(). Just tell me if you want these reverted.
There was a problem hiding this comment.
The idea with the original do_* calls on Package was to keep the interface exposed to commands really simple. I think this part, especially since you have to refer to the stage variable explicitly, is kind of a leaky abstraction. I'd rather the package.py encapsulate the hard part... Is there a reason to require everyone who deals with Package to know the details of how staging is implemented? Seems like too much to expect from the caller.
|
I fixed a few things and merged -- I changed |
eckit: set cmake BLA_VENDOR
The issues are similar to the ones solved in ad103dc and were introduced by (my) stage refactoring.
@tgamblin : if you think it may be better, I could remove the explicit call to create in
_make_stageand use the stage as a context manager infetch,stage, etc. I'll also try to have a look in another PR how hard it is to write regression tests for these issues.