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

move prepare_step before extract_step #3004

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions easybuild/framework/easyblock.py
Original file line number Diff line number Diff line change
Expand Up @@ -1859,6 +1859,9 @@ def extract_step(self):
else:
raise EasyBuildError("Unpacking source %s failed", src['name'])

# guess directory to start configure/build/install process in, and move there
self.guess_start_dir()

def patch_step(self, beginpath=None):
"""
Apply the patches
Expand Down Expand Up @@ -1964,10 +1967,6 @@ def prepare_step(self, start_dir=True):
self.log.info("Loading extra modules: %s", extra_modules)
self.modules_tool.load(extra_modules)

# guess directory to start configure/build/install process in, and move there
if start_dir:
self.guess_start_dir()

def configure_step(self):
"""Configure build (abstract method)."""
raise NotImplementedError
Expand Down Expand Up @@ -2887,9 +2886,9 @@ def install_step_spec(initial):
steps_part1 = [
(FETCH_STEP, 'fetching files', [lambda x: x.fetch_step], False),
ready_step_spec(True),
prepare_step_spec,
source_step_spec(True),
patch_step_spec,
prepare_step_spec,
configure_step_spec,
build_step_spec,
test_step_spec,
Expand All @@ -2901,9 +2900,9 @@ def install_step_spec(initial):
# not all parts of all steps need to be rerun (see e.g., ready, prepare)
steps_part2 = [
ready_step_spec(False),
prepare_step_spec,
source_step_spec(False),
patch_step_spec,
prepare_step_spec,
configure_step_spec,
build_step_spec,
test_step_spec,
Expand Down
2 changes: 1 addition & 1 deletion easybuild/framework/easyconfig/tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -549,7 +549,7 @@ def dump_env_script(easyconfigs):

# prepare build environment (in dry run mode)
app.check_readiness_step()
app.prepare_step(start_dir=False)
app.prepare_step()

# compose script
ecfile = os.path.basename(ec.path)
Expand Down
2 changes: 1 addition & 1 deletion test/framework/easyblock.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ def test_load_module(self):

self.mock_stderr(True)
self.mock_stdout(True)
eb.prepare_step(start_dir=False)
eb.prepare_step()
stderr = self.get_stderr()
stdout = self.get_stdout()
self.mock_stderr(False)
Expand Down