def list_preprocessors(self): results = [] preprocessors.register_extensions( self.yaml.get('extensions', {}).get('preprocessors', []), self.root, ) preprocessor_config = copy.deepcopy(self.yaml.get('preprocessors', [])) legacy_preprocessors = [] for params in preprocessor_config: kind = params.pop('kind') legacy_preprocessors.append(kind) try: preprocessor = preprocessors.make_preprocessor( kind, params, self) results.append(preprocessor) except ValueError as err: # New extensions don't exists and are considered a value error. pass # TODO: Show deprecation message in the future. # if legacy_preprocessors: # legacy_message = 'Legacy preprocessors are deprecated and will be removed in the future: {}' # self.deprecated( # 'legacy_preprocessors', # legacy_message.format(', '.join(legacy_preprocessors)), # url='https://grow.dev/migration/1.0.0') return results
def list_preprocessors(self): results = [] preprocessors.register_extensions( self.yaml.get('extensions', {}).get('preprocessors', []), self.root, ) preprocessor_config = copy.deepcopy(self.yaml.get('preprocessors', [])) for params in preprocessor_config: kind = params.pop('kind') preprocessor = preprocessors.make_preprocessor(kind, params, self) results.append(preprocessor) return results
def list_preprocessors(self): results = [] preprocessors.register_extensions( self.yaml.get('extensions', {}).get('preprocessors', []), self.root, ) preprocessor_config = copy.deepcopy(self.yaml.get('preprocessors', [])) for params in preprocessor_config: kind = params.pop('kind') try: preprocessor = preprocessors.make_preprocessor( kind, params, self) results.append(preprocessor) except ValueError as err: # New extensions will not show up here. self.logger.info(err) return results
def list_preprocessors(self): results = [] preprocessors.register_extensions( self.yaml.get('extensions', {}).get('preprocessors', []), self.root, ) preprocessor_config = copy.deepcopy(self.yaml.get('preprocessors', [])) for params in preprocessor_config: kind = params.pop('kind') try: preprocessor = preprocessors.make_preprocessor( kind, params, self) results.append(preprocessor) except ValueError as err: # New extensions don't exists and are considered a value error. pass return results