# cwltool.run_job

Only used when there is a job script or CWLTOOL_FORCE_SHELL_POPEN=1.

## Functions

`handle_software_environment`(cwl_env, script) | Update the provided environment dict by running the script.
`main`(argv) | Read in the configuration JSON and execute the commands.

## Module Contents

cwltool.run_job.handle_software_environment(cwl_env, script)

  Update the provided environment dict by running the script.

  Parameters:

    - cwl_env (dict[str, str])

    - script (str)

  Return type:

    dict[str, str]

cwltool.run_job.main(argv)

  Read in the configuration JSON and execute the commands.

  The first argument is the path to the JSON dictionary file containing keys:

    “commands”: an array of strings that represents the command line to run “cwd”: A string specifying which directory to run in “env”: a dictionary of strings containing the environment variables to set “stdin_path”: a string (or a null) giving the path that should be piped to STDIN “stdout_path”: a string (or a null) giving the path that should receive the STDOUT “stderr_path”: a string (or a null) giving the path that should receive the STDERR

  The second argument is optional, it specifies a shell script to execute prior,

    and the environment variables it sets will be combined with the environment variables from the “env” key in the JSON dictionary from the first argument.

  Parameters:

    argv (list[str])

  Return type:

    int