If you want to move the "import" from diecutter.service to diecutter.settings, you can have some function in settings.py that performs the config.maybe_dotted(). Then in diecutter.service, you would call this function instead of using TEMPLATE_ENGINE_MAPPINGS.