<commit_before>"""Digital leben workflow."""
from adhocracy_core.workflows import add_workflow
from adhocracy_core.workflows.standard import standard_meta

digital_leben_meta =  standard_meta \
                      .transform(('states', 'participate', 'acm'),
                                 {'principals': [                   'participant', 'moderator', 'creator', 'initiator'],  # noqa
                                'permissions':
                                  [['create_proposal',             None,          None,        None,     'Allow'],  # noqa
                                   ['edit_proposal',               None,          None,       'Allow',   'Allow'],  # noqa
                                   ['create_comment',             'Allow',       'Allow',      None,     'Allow'],  # noqa
                                   ['edit_comment',                None,          None,       'Allow',    None  ],  # noqa
                                   ['create_rate',                'Allow',        None,        None,      None  ],  # noqa
                                   ['edit_rate',                   None,          None,       'Allow',    None  ],  # noqa
                                   ]})


def includeme(config):
    """Add workflow."""
    add_workflow(config.registry, digital_leben_meta, 'digital_leben')
<commit_msg>Make flake8 happy for spd<commit_after>"""Digital leben workflow."""
from adhocracy_core.workflows import add_workflow
from adhocracy_core.workflows.standard import standard_meta

digital_leben_meta = standard_meta \
                     .transform(('states', 'participate', 'acm'),
                                {'principals':                  ['participant', 'moderator', 'creator', 'initiator'],  # noqa
                                 'permissions':
                                 [['create_proposal',             None,          None,        None,     'Allow'],  # noqa
                                  ['edit_proposal',               None,          None,       'Allow',   'Allow'],  # noqa
                                  ['create_comment',             'Allow',       'Allow',      None,     'Allow'],  # noqa
                                  ['edit_comment',                None,          None,       'Allow',    None],  # noqa
                                  ['create_rate',                'Allow',        None,        None,      None],  # noqa
                                  ['edit_rate',                   None,          None,       'Allow',    None],  # noqa
                                 ]})


def includeme(config):
    """Add workflow."""
    add_workflow(config.registry, digital_leben_meta, 'digital_leben')

{'fraction_non_alphanumeric': 0.11094564408041697, 'fraction_numerical': 0.00037230081906180194, 'mean_word_length': 1.0813323005422153, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 16, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1460186', 'n_tokens_mistral': 685, 'n_tokens_neox': 636, 'n_words': 136}