It appears my thick-headedness is acting up again. How would I go
about adding that from the command line? How DOES one run
daily_cleanup.py?

On Mar 6, 1:50 pm, "akonsu" <[EMAIL PROTECTED]> wrote:
> sorry i was not clear...
>
> the document explains how to use settings without seting the
> DJANGO_SETTINGS_MODULE variable. which seems to be the problem in your
> situation.
>
> and example from the document:
>
> from django.conf import settings
>
> settings.configure(DEBUG=True, TEMPLATE_DEBUG=True,
>     TEMPLATE_DIRS=('/home/web-apps/myapp', '/home/web-apps/base'))
>
> On Mar 6, 2:17 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
> wrote:
>
> > Thanks, but I don't have any reason to believe I have a problem with
> > my settings file. I think I'm not running daily_cleanup.py properly.
>
> > Unless I'm totally misunderstanding what you're trying to tell me.
>
> > On Mar 6, 1:09 pm, "akonsu" <[EMAIL PROTECTED]> wrote:
>
> > > hello,
>
> > > this might help:
>
> > >http://www.djangoproject.com/documentation/settings/#using-settings-w...
>
> > > cheers
> > > konstantin
>
> > > On Mar 6, 2:05 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
> > > wrote:
>
> > > > I think I need to clean out old sessions, but when I try to manually
> > > > run daily_cleanup.py from the command line, I'm getting:
>
> > > > Traceback (most recent call last):
> > > >   File "daily_cleanup.py", line 8, in ?
> > > >     from django.db import backend, connection, transaction
> > > >   File "/home2/baxter/lib/python2.4/django/db/__init__.py", line 7,
> > > > in ?
> > > >     if not settings.DATABASE_ENGINE:
> > > >   File "/home2/baxter/lib/python2.4/django/conf/__init__.py", line 27,
> > > > in __getattr__
> > > >     self._import_settings()
> > > >   File "/home2/baxter/lib/python2.4/django/conf/__init__.py", line 52,
> > > > in _import_settings
> > > >     raise EnvironmentError, "Environment variable %s is undefined." %
> > > > ENVIRONMENT_VARIABLE
> > > > EnvironmentError: Environment variable DJANGO_SETTINGS_MODULE is
> > > > undefined.
>
> > > > What am I doing wrong?- Hide quoted text -
>
> > - Show quoted text -


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to