diff --git a/astropy_helpers b/astropy_helpers index 9a7319ddc1b..3bb39bdc735 160000 --- a/astropy_helpers +++ b/astropy_helpers @@ -1 +1 @@ -Subproject commit 9a7319ddc1b013babb9c4f9451ae165c42a31834 +Subproject commit 3bb39bdc735eb5ac52490a4e3d5e0b05b077d3fd diff --git a/tardis/io/config_reader.py b/tardis/io/config_reader.py index bedb26835e7..c6bbb4a888c 100644 --- a/tardis/io/config_reader.py +++ b/tardis/io/config_reader.py @@ -736,7 +736,7 @@ def from_yaml(cls, fname, test_parser=False): @classmethod def from_config_dict(cls, config_dict, atom_data=None, test_parser=False, - config_definition_file=None): + config_definition_file=None, validate=True): """ Validating and subsequently parsing a config file. @@ -759,6 +759,9 @@ def from_config_dict(cls, config_dict, atom_data=None, test_parser=False, path to config definition file, if `None` will be set to the default in the `data` directory that ships with TARDIS + validate: ~bool + Turn validation on or off. + Returns ------- @@ -771,9 +774,11 @@ def from_config_dict(cls, config_dict, atom_data=None, test_parser=False, config_definition_file = default_config_definition_file config_definition = yaml.load(open(config_definition_file)) - - validated_config_dict = ConfigurationValidator(config_definition, + if validate: + validated_config_dict = ConfigurationValidator(config_definition, config_dict).get_config() + else: + validated_config_dict = config_dict #First let's see if we can find an atom_db anywhere: if test_parser: