<commit_before>#  This Source Code Form is subject to the terms of the Mozilla Public
#  License, v. 2.0. If a copy of the MPL was not distributed with this
#  file, You can obtain one at http://mozilla.org/MPL/2.0/.

# -*- coding: utf-8 -*-


from django import apps


class AppConfig(apps.AppConfig):

    name = 'sensor.core'
    verbose_name = 'Sensor Core'<commit_msg>Register the signal handlers on sensor.core startup<commit_after>#  This Source Code Form is subject to the terms of the Mozilla Public
#  License, v. 2.0. If a copy of the MPL was not distributed with this
#  file, You can obtain one at http://mozilla.org/MPL/2.0/.

# -*- coding: utf-8 -*-


from django import apps
from django.db.models.signals import pre_save

from sensor.core.signals.handlers import (
    create_generic_sensor_for_sensor,
    create_generic_event_for_event)


class AppConfig(apps.AppConfig):

    name = 'sensor.core'
    verbose_name = 'Sensor Core'

    def ready(self):

        pre_save.connect(create_generic_sensor_for_sensor)
        pre_save.connect(create_generic_event_for_event)
{'fraction_non_alphanumeric': 0.09107635694572216, 'fraction_numerical': 0.00919963201471941, 'mean_word_length': 3.5523012552301254, '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': '3579884', 'n_tokens_mistral': 351, 'n_tokens_neox': 333, 'n_words': 114}