nside_wefa.utils.checks

Utility functions to implement Django system checks for nside_wefa.

This module provides helpers used by the nside_wefa Django apps to validate project configuration and application ordering:

  • check_nside_wefa_settings: validates NSIDE_WEFA.<SECTION> configuration.

  • check_apps_dependencies_order: verifies INSTALLED_APPS ordering for dependent apps.

  • Primitive validators (validate_bool, validate_optional_positive_int, validate_string_list, validate_dotted_path_callable, validate_model_label) composable inside custom_validators mappings.

See also - Django system check framework: https://docs.djangoproject.com/en/stable/topics/checks/

Functions

check_apps_dependencies_order(dependencies)

Verify the ordering of dependent apps in INSTALLED_APPS.

check_nside_wefa_settings(section_name, ...)

Validate a subsection of the NSIDE_WEFA settings.

validate_bool(setting_path)

Return a validator that ensures the value is a boolean.

validate_dotted_path_callable(setting_path)

Return a validator that resolves the value as a dotted-path callable.

validate_model_label(label)

Resolve an "app_label.ModelName" string via the Django app registry.

validate_model_label_dict(setting_path)

Return a validator that ensures the value is a {label: dict} mapping.

validate_optional_positive_int(setting_path)

Return a validator that accepts None or a positive integer.

validate_string_list(setting_path[, allowed])

Return a validator that ensures the value is a list of non-empty strings.