# Path: hedwig/django/signals.py
# def register_hedwig_callbacks():
#     LOGGER.info("Registering post_save and post_delete signal callbacks")
#     post_save.connect(saved_hedwig_models, weak=False, dispatch_uid="saved_hedwig_models")
#     post_delete.connect(deleted_hedwig_models, weak=False, dispatch_uid="deleted_hedwig_models")
# 
# Path: hedwig/django/settings.py
# HEDWIG_USER_SETTINGS = getattr(settings, 'HEDWIG', None)
# HEDWIG_DJANGO_USER_SETTINGS = getattr(settings, 'HEDWIG_DJANGO', None)
# DJANGO_DEFAULTS = {
#     'MODEL_SIGNALS': False,
#     'HIDE_FIELDS': False,
#     'NATURAL_PRIMARY_KEYS': True,
#     'NATURAL_FOREIGN_KEYS': True
# }
# MODEL_DEFAULTS = {
#     'fields': not bool(hedwig_django_settings.HIDE_FIELDS),
#     'natural_primary_keys': bool(hedwig_django_settings.NATURAL_PRIMARY_KEYS),
#     'natural_foreign_keys': bool(hedwig_django_settings.NATURAL_FOREIGN_KEYS),
#     'created': True,
#     'updated': True,
#     'deleted': True
# }


from django.apps.config import AppConfig
from .signals import register_hedwig_callbacks
from .settings import hedwig_django_settings


class HedwigAppConfig(AppConfig):
    name = 'hedwig.django'
    label = 'hedwig.django'

    def ready(self):
        if hedwig_django_settings.MODEL_SIGNALS:

# Path: hedwig/django/signals.py
# def register_hedwig_callbacks():
#     LOGGER.info("Registering post_save and post_delete signal callbacks")
#     post_save.connect(saved_hedwig_models, weak=False, dispatch_uid="saved_hedwig_models")
#     post_delete.connect(deleted_hedwig_models, weak=False, dispatch_uid="deleted_hedwig_models")
# 
# Path: hedwig/django/settings.py
# HEDWIG_USER_SETTINGS = getattr(settings, 'HEDWIG', None)
# HEDWIG_DJANGO_USER_SETTINGS = getattr(settings, 'HEDWIG_DJANGO', None)
# DJANGO_DEFAULTS = {
#     'MODEL_SIGNALS': False,
#     'HIDE_FIELDS': False,
#     'NATURAL_PRIMARY_KEYS': True,
#     'NATURAL_FOREIGN_KEYS': True
# }
# MODEL_DEFAULTS = {
#     'fields': not bool(hedwig_django_settings.HIDE_FIELDS),
#     'natural_primary_keys': bool(hedwig_django_settings.NATURAL_PRIMARY_KEYS),
#     'natural_foreign_keys': bool(hedwig_django_settings.NATURAL_FOREIGN_KEYS),
#     'created': True,
#     'updated': True,
#     'deleted': True
# }


# Path: hedwig/django/apps.py
from django.apps.config import AppConfig
from .signals import register_hedwig_callbacks
from .settings import hedwig_django_settings



class HedwigAppConfig(AppConfig):
    name = 'hedwig.django'
    label = 'hedwig.django'

    def ready(self):
        if hedwig_django_settings.MODEL_SIGNALS:

            register_hedwig_callbacks()