move prepare_step before extract_step #3004
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
cfr. #1376
I don't actually intend to get this merged, I just want to get this on record...
I started looking into this, and it quickly became clear that @wpoely86's view was right: moving up the
prepare_step
such that dependencies required for unpacking sources is quite intrusive to do.The
guess_start_dir()
call had to be moved fromprepare_step
to the end ofextract_step
, since it obviously requires that the sources are unpacked. That's a fairly minor issue, more like a logical consequence (you could even argue thatguess_start_dir()
is out of place inprepare_step
, I guess).As anticipated in #1376, this impacts easyblocks where the
prepare_step
is customized and it is assumed that the sources are already unpacked when it is being called. At first sight, this affects at least two software-specific easyblocks in the central repository:DL_POLY_Classic
andOpenCV
.Although it's fairly easy to fix them to take into account that
prepare_step
is run beforeextract_step
, it highlights the impact that the change has (we should take into account that there are other (customized) easyblocks outside of the central repository that may be affected).This change also breaks a test (
test_guess_start_dir
), which may be easy to fix (it looks like a problem with assumptions made by the test itself, rather than an actual problem being caught), but it's still a sign of trouble...