Commit 97c1e303 authored by Markus Scheidgen's avatar Markus Scheidgen
Browse files

Fixed list of code_names.

parent fafdb25c
Pipeline #82611 passed with stages
in 22 minutes and 54 seconds
Subproject commit e1f873f104d4ce64815636251c8e30971a9fcbda
Subproject commit 7ed44cab4410099208f5e399bfa4c1dc2e9c29fe
......@@ -478,10 +478,13 @@ parser_dict['parser/octopus'] = parser_dict['parsers/octopus']
parser_dict['parser/onetep'] = parser_dict['parsers/onetep']
# register code names as possible statistic value to the dft datamodel
code_names = sorted(
set([
getattr(parser, 'code_name')
for parser in parsers
if parser.domain == 'dft' and getattr(parser, 'code_name', None) is not None and getattr(parser, 'code_name') != 'currupted mainfile']),
key=lambda code_name: code_name.lower())
datamodel.DFTMetadata.code_name.a_search.statistic_values = code_names + [config.services.unavailable_value, config.services.not_processed_value]
code_names = []
for parser in parsers:
if parser.domain == 'dft' and \
getattr(parser, 'code_name', None) is not None and \
getattr(parser, 'code_name') != 'currupted mainfile' and \
getattr(parser, 'code_name') != 'Template':
code_names.append(getattr(parser, 'code_name'))
code_names = sorted(set(code_names), key=lambda code_name: code_name.lower())
datamodel.DFTMetadata.code_name.a_search.statistic_values = code_names + [
config.services.unavailable_value, config.services.not_processed_value]
Supports Markdown
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