Commit 1a0e718c authored by Samuel GAIST's avatar Samuel GAIST

[backend][helpers] Implement adding run_arguments to configuration

parent f3e8194d
Pipeline #15777 canceled with stage
in 109 minutes and 6 seconds
......@@ -42,6 +42,9 @@ from ..experiments.models import Experiment
from ..experiments.models import Block
from ..experiments.models import CachedFile
from ..experiments.models import Result as CacheResult
from ..backend.models import Environment
from .models import Queue
from .models import Job
from .models import JobSplit
......@@ -391,6 +394,17 @@ def get_configuration_for_split(split):
if (split.start_index is not None) and (split.end_index is not None):
configuration['range'] = [split.start_index, split.end_index]
# Grab environment from configuration and add run arguments here.
environment_info = configuration['environment']
environment = Environment.objects.get(
version=environment_info['version'],
name=environment_info['name']
)
configuration['run_arguments'] = environment.build_run_arguments()
return configuration
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment