<commit_before># -*- coding: utf-8 -*-
from __future__ import unicode_literals

import logging


from udata.core import MODULES

log = logging.getLogger(__name__)


def init_app(app):
    # Load all core actvitiess
    for module in MODULES:
        try:
            __import__('udata.core.{0}.activities'.format(module))
        except ImportError:
            pass
        except Exception as e:
            log.error('Unable to import activities for %s: %s', module, e)

    # Load plugins API
    for plugin in app.config['PLUGINS']:
        name = 'udata.ext.{0}.activities'.format(plugin)
        try:
            __import__(name)
        except ImportError:
            pass
        except Exception as e:
            log.error('Error importing %s: %s', name, e)
<commit_msg>Explicit core activities import<commit_after># -*- coding: utf-8 -*-
from __future__ import unicode_literals

import logging


log = logging.getLogger(__name__)


def init_app(app):
    # Load all core actvitiess
    import udata.core.user.activities
    import udata.core.dataset.activities
    import udata.core.reuse.activities

    # Load plugins API
    for plugin in app.config['PLUGINS']:
        name = 'udata.ext.{0}.activities'.format(plugin)
        try:
            __import__(name)
        except ImportError:
            pass
        except Exception as e:
            log.error('Error importing %s: %s', name, e)

{'fraction_non_alphanumeric': 0.10070921985815603, 'fraction_numerical': 0.0035460992907801418, 'mean_word_length': 2.375598086124402, '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': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4129127', 'n_tokens_mistral': 424, 'n_tokens_neox': 415, 'n_words': 117}