Skip to Content

Setting up django settings environment within a python script

Posted on One min read

Found at softwaremaniacs.org

import settings
from django.core.management import setup_environ

setup_environ(settings)

NOTE: Deprecated in Django 1.4 (“Release notes”)

comments powered by Disqus