shapepipe.pipeline.config
shapepipe.pipeline.config¶
CONFIGURATION FILE HANDLING.
This module defines methods for handling the pipeline configuration file.
- Author
Samuel Farrens <samuel.farrens@cea.fr>
- class CustomParser(defaults=None, dict_type=<class 'dict'>, allow_no_value=False, *, delimiters=('=', ':'), comment_prefixes=('#', ';'), inline_comment_prefixes=None, strict=True, empty_lines_in_values=True, default_section='DEFAULT', interpolation=<object object>, converters=<object object>)[source]¶
Bases:
configparser.ConfigParser
Custom Parser.
This class adds functionality to the
ConfigParser
class.- getexpanded(section, option)[source]¶
Get Expanded.
This method expands enviroment varibles obtaiened using the get method.
- getlist(section, option, delimiter=',')[source]¶
Get List.
This method retrieves a list of strings separated by a given delimiter.
- _abc_impl = <_abc._abc_data object>¶
- class SetUpParser(file_name)[source]¶
Bases:
object
Set Up Parser.
This class sets up an instance of
CustomParser
and checks the pipeline related parameters.- Parameters
file_name (str) – Configuration file name
- property file_name¶
Set file name.
This sets the configuration file name.
- Raises
IOError – For non existent configuration file
- _set_execution_options()[source]¶
Set Execution Options.
This method checks the execution options in the configuration file.
- Raises
RuntimeError – For no module runner specified
ImportError – For non-existent module runner
- _set_file_options()[source]¶
Set File Options.
This module checks the file options in the configuration file.
- Raises
RuntimeError – For no input directory specified
OSError – For non-existent input directory
RuntimeError – For no output directory specified
OSError – For non-existent output directory
- _set_worker_options()[source]¶
Set Worker Options.
This module checks the worker options in the configuration file.