Skip to content

Commit d7f82e6

Browse files
author
Vasileios Karakasis
authored
Merge branch 'master' into docs/renew-tutorial
2 parents ba0e0db + 500e4d3 commit d7f82e6

File tree

5 files changed

+27
-18
lines changed

5 files changed

+27
-18
lines changed

bin/reframe

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,9 @@
88
import os
99
import sys
1010

11-
prefix = os.path.join(os.path.abspath(os.path.dirname(__file__)), '..')
11+
prefix = os.path.normpath(
12+
os.path.join(os.path.abspath(os.path.dirname(__file__)), '..')
13+
)
1214
external = os.path.join(prefix, 'external')
1315
sys.path = [prefix, external] + sys.path
1416

config/cscs-ci.py

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@
2626
],
2727
'access': [
2828
'--constraint=gpu',
29-
'--partition=cscsci'
29+
'--partition=cscsci',
30+
'--account=jenscscs'
3031
],
3132
'environs': [
3233
'builtin'
@@ -61,7 +62,8 @@
6162
'daint-gpu'
6263
],
6364
'access': [
64-
'--constraint=gpu'
65+
'--constraint=gpu',
66+
'--account=jenscscs'
6567
],
6668
'environs': [
6769
'builtin'
@@ -85,7 +87,8 @@
8587
'daint-gpu'
8688
],
8789
'access': [
88-
'proc=gpu'
90+
'proc=gpu',
91+
'-A jenscscs'
8992
],
9093
'environs': [
9194
'builtin'
@@ -101,7 +104,8 @@
101104
'daint-gpu'
102105
],
103106
'access': [
104-
'-l proc=gpu'
107+
'-l proc=gpu',
108+
'-A jenscscs'
105109
],
106110
'environs': [
107111
'builtin'

reframe/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,9 @@
88

99

1010
VERSION = '3.1-dev1'
11-
INSTALL_PREFIX = os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))
11+
INSTALL_PREFIX = os.path.normpath(
12+
os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))
13+
)
1214
MIN_PYTHON_VERSION = (3, 6, 0)
1315

1416
# Check python version

reframe/core/decorators.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,9 +227,13 @@ def require_deps(func):
227227
The converted arguments are essentially functions accepting a single
228228
argument, which is the target test's programming environment.
229229
230+
Additionally, this decorator will attach the function to run *after* the
231+
test's setup phase, but *before* any other "post_setup" pipeline hook.
232+
230233
This decorator is also directly available under the :mod:`reframe` module.
231234
232235
.. versionadded:: 2.21
236+
233237
'''
234238
tests = inspect.getfullargspec(func).args[1:]
235239
func._rfm_resolve_deps = True

reframe/frontend/cli.py

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -418,6 +418,15 @@ def main():
418418
for err in options.update_config(site_config):
419419
printer.warning(str(err))
420420

421+
# Update options from the selected execution mode
422+
if options.mode:
423+
mode_args = site_config.get(f'modes/@{options.mode}/options')
424+
425+
# Parse the mode's options and reparse the command-line
426+
options = argparser.parse_args(mode_args)
427+
options = argparser.parse_args(namespace=options.cmd_options)
428+
options.update_config(site_config)
429+
421430
logging.configure_logging(site_config)
422431
except (OSError, ConfigError) as e:
423432
printer.error(f'failed to load configuration: {e}')
@@ -447,18 +456,6 @@ def main():
447456
printer.error('could not load module mappings: %s' % e)
448457
sys.exit(1)
449458

450-
if options.mode:
451-
try:
452-
mode_args = rt.get_option(f'modes/@{options.mode}/options')
453-
454-
# Parse the mode's options and reparse the command-line
455-
options = argparser.parse_args(mode_args)
456-
options = argparser.parse_args(namespace=options.cmd_options)
457-
options.update_config(rt.site_config)
458-
except ConfigError as e:
459-
printer.error('could not obtain execution mode: %s' % e)
460-
sys.exit(1)
461-
462459
if (os_ext.samefile(rt.stage_prefix, rt.output_prefix) and
463460
not site_config.get('general/0/keep_stage_files')):
464461
printer.error("stage and output refer to the same directory; "

0 commit comments

Comments
 (0)