Ah thanks Brad, I get the same as Bradley now..

Rick

On Apr 7, 1:53 pm, Brad Pitcher <[email protected]> wrote:
> Did you use "./manage.py shell" to get into a shell, or just "python".
> Because you should use "./manage.py shell"
>
> On Wed, Apr 7, 2010 at 1:50 PM, Ricko <[email protected]> wrote:
> > I cant even import livesettings:
>
> >  File "<stdin>", line 1, in <module>
> >  File "/Library/Python/2.5/site-packages/django_livesettings-1.4_3-
> > py2.5.egg/livesettings/__init__.py", line 14, in <module>
> >    from functions import *
> >   File "/Library/Python/2.5/site-packages/django_livesettings-1.4_3-
> > py2.5.egg/livesettings/functions.py", line 2, in <module>
> >    from livesettings import values
> >   File "/Library/Python/2.5/site-packages/django_livesettings-1.4_3-
> > py2.5.egg/livesettings/values.py", line 12, in <module>
> >    from livesettings.models import find_setting, LongSetting,
> > Setting, SettingNotSet
> >   File "/Library/Python/2.5/site-packages/django_livesettings-1.4_3-
> > py2.5.egg/livesettings/models.py", line 2, in <module>
> >    from django.contrib.sites.models import Site
> >  File "/Library/Python/2.5/site-packages/django/contrib/sites/
> > models.py", line 1, in <module>
> >    from django.db import models
> >  File "/Library/Python/2.5/site-packages/django/db/__init__.py", line
> > 10, in <module>
> >    if not settings.DATABASE_ENGINE:
> >  File "/Library/Python/2.5/site-packages/django/utils/functional.py",
> > line 269, in __getattr__
> >    self._setup()
> >  File "/Library/Python/2.5/site-packages/django/conf/__init__.py",
> > line 38, in _setup
> >    raise ImportError("Settings cannot be imported, because
> > environment variable %s is undefined." % ENVIRONMENT_VARIABLE)
> > ImportError: Settings cannot be imported, because environment variable
> > DJANGO_SETTINGS_MODULE is undefined.
>
> > But here it is in the local_settings.py:
>
> > # Only set these if Satchmo is part of another Django project
> > #These are used when loading the test data
> > SITE_NAME = "simple"
> > MEDIA_ROOT = os.path.join(SATCHMO_DIRNAME, 'static/')
> > DJANGO_PROJECT = 'simple'
> > DJANGO_SETTINGS_MODULE = 'simple.settings'
>
> > Rick
>
> > On Apr 7, 1:40 pm, Chris Moffitt <[email protected]> wrote:
> > > Interesting. I'm not at my dev box right now so I'll have to play with
> > this
> > > later this evening. I'm not sure why it's erroring out. I'll have to see
> > if
> > > I can find a way to reproduce this.
>
> > > -Chris
>
> > > On Wed, Apr 7, 2010 at 3:13 PM, bradleykay <[email protected]>
> > wrote:
> > > > Is this what you mean?
>
> > > > >>> import livesettings
> > > > >>> from livesettings import config_value
> > > > >>> config_value('PRODUCT', 'NUM_DISPLAY')
> > > > Traceback (most recent call last):
> > > >  File "<console>", line 1, in <module>
> > > >  File "/home/brad/.local/lib/python2.6/site-packages/livesettings/
> > > > functions.py", line 204, in config_value
> > > >     return config_get(group, key).value
> > > >   File "/home/brad/.local/lib/python2.6/site-packages/livesettings/
> > > > functions.py", line 149, in config_get
> > > >    return ConfigurationSettings().get_config(group, key)
> > > >  File "/home/brad/.local/lib/python2.6/site-packages/livesettings/
> > > > functions.py", line 66, in get_config
> > > >     raise SettingNotSet('%s config group does not exist' % group)
> > > > SettingNotSet
>
> > > > On Apr 7, 12:55 pm, Chris Moffitt <[email protected]> wrote:
> > > > > If you try to access the a product value from python manage.py shell,
> > > > what
> > > > > do you see?
>
> > > > > -Chris
>
> > > > > On Wed, Apr 7, 2010 at 12:56 PM, bradleykay <[email protected]>
> > > > wrote:
> > > > > > Hey guys.  I don't mean to interrupt, but I think I know what the
> > > > > > problem is.  I am experiencing it as well.  I believe the problem
> > is
> > > > > > that the PRODUCT group of settings are not correctly getting
> > > > > > registered with livesettings.  If you go to
> > > > > >http://localhost:8000/settings/
> > > > > > after starting up the 'simple' site, there are no product settings
> > > > > > there.  Still trying to figure out the cause of the error though...
>
> > > > > > On Apr 7, 10:48 am, Ricko <[email protected]> wrote:
> > > > > > > I'm trying to get the 'Simple' Satchmo project working, as I
> > figure
> > > > > > > all the settings will be correct on there. I haven't changed
> > anything
> > > > > > > there either in settings.py or local_settings.py, so it will all
> > be
> > > > > > > the same as you see (locmem cache etc)
>
> > > > > > > From there, I run python manage.py test livesettings, all tests
> > pass.
>
> > > > > > > Then I run syncdb, I get:
>
> > > > > > > Not synced (use migrations):
> > > > > > >  - product
> > > > > > > (use ./manage.py migrate to migrate these)
>
> > > > > > > Then I runserver, it loads up. I can then go to the admin login
> > page
> > > > > > > fine, but nowhere else, everywhere else fails with the 'Settings
> > Not
> > > > > > > Set' error, specifically :
>
> > > > > > > PRODUCT.NUM_DISPLAY
>
> > > > > > > Something I noticed which probably isn't relevant, but if I go to
> > > > > > > Satchmo>apps>I don't see 'Livesettings' or 'KeyedCache' dirs. Is
> > that
> > > > > > > right, shouldn't they be there?
>
> > > > > > > Rick
>
> > > > > > > On Apr 7, 10:35 am, Chris Moffitt <[email protected]> wrote:
>
> > > > > > > > Your cache settings should be in your local_settings.py file.
>
> > > > > > > > Your DB_ENGINE variable doesn't have to be the full dotted
> > path.
> > > > > > sqlite3
> > > > > > > > should be sufficient
>
> > > > > > > > I doubt this is the problem but I thought I'd mention it.
>
> > > > > > > > Also, please use dpaste.com (or something similar) to post
> > links
> > > > to
> > > > > > your
> > > > > > > > full config files.
>
> > > > > > > > Thanks,
> > > > > > > > Chris
>
> > > > > > > > On Wed, Apr 7, 2010 at 11:20 AM, Ricko <[email protected]>
> > > > wrote:
> > > > > > > > > Hi Chris,
>
> > > > > > > > > I'm not sure about the cache backend, where do I look?
>
> > > > > > > > > My DB is sqlite3.
>
> > > > > > > > > I can't see any livesettings config settings in my
> > settings.py
> > > > file.
> > > > > > > > > Should they be there, is that the problem?Here is my
> > settings.py
> > > > > > file:
>
> > > > > > > > > import os
>
> > > > > > > > > DIRNAME = os.path.abspath(os.path.dirname(__file__))
> > > > > > > > > LOCAL_DEV = True
>
> > > > > > > > > MEDIA_ROOT = '/Users/ricko/Documents/Django
> > > > Projects/Consortium/DEV/
> > > > > > > > > www/artvswall/static'
> > > > > > > > > MEDIA_URL = 'http://artvswall.com/static/'
>
> > > > > > > > > AUTHENTICATION_BACKENDS = (
> > > > > > > > >    'satchmo_store.accounts.email-auth.EmailBackend',
> > > > > > > > >    'django.contrib.auth.backends.ModelBackend'
> > > > > > > > >    )
>
> > > > > > > > > #### Satchmo unique variables ####
> > > > > > > > > from django.conf.urls.defaults import patterns, include
> > > > > > > > > SATCHMO_SETTINGS = {
> > > > > > > > >                    'SHOP_BASE' : '/store',
> > > > > > > > >                    'MULTISHOP' : False,
> > > > > > > > >                    'SHOP_URLS' :
> > > > > > > > > patterns('satchmo_store.shop.views',)
> > > > > > > > >                    }
>
> > > > > > > > > # Load the local settings
> > > > > > > > > from local_settings import *
>
> > > > > > > > > DEBUG = True
> > > > > > > > > TEMPLATE_DEBUG = DEBUG
>
> > > > > > > > > ADMINS = (
> > > > > > > > >    # ('Your Name', '[email protected]'),
> > > > > > > > > )
>
> > > > > > > > > MANAGERS = ADMINS
>
> > > > > > > > > DATABASE_ENGINE = 'django.db.backends.sqlite3'
> > > > > > > > > DATABASE_NAME = 'artvswall.sqlite3'
> > > > > > > > > DATABASE_USER = ''
> > > > > > > > > DATABASE_PASSWORD = ''
> > > > > > > > > DATABASE_HOST = ''
> > > > > > > > > DATABASE_PORT = ''
>
> > > > > > > > > # Local time zone for this installation. Choices can be found
> > > > here:
> > > > > > > > > #http://en.wikipedia.org/wiki/List_of_tz_zones_by_name
> > > > > > > > > # although not all choices may be available on all operating
> > > > systems.
> > > > > > > > > # If running in a Windows environment this must be set to the
> > > > same as
> > > > > > > > > your
> > > > > > > > > # system time zone.
> > > > > > > > > TIME_ZONE = 'America/Chicago'
>
> > > > > > > > > # Language code for this installation. All choices can be
> > found
> > > > here:
> > > > > > > > > #http://www.i18nguy.com/unicode/language-identifiers.html
> > > > > > > > > LANGUAGE_CODE = 'en-us'
>
> > > > > > > > > SITE_ID = 1
>
> > > > > > > > > # If you set this to False, Django will make some
> > optimizations
> > > > so as
> > > > > > > > > not
> > > > > > > > > # to load the internationalization machinery.
> > > > > > > > > USE_I18N = False
>
> > > > > > > > > # URL prefix for admin media -- CSS, JavaScript and images.
> > Make
> > > > sure
> > > > > > > > > to use a
> > > > > > > > > # trailing slash.
> > > > > > > > > # Examples: "http://foo.com/media/";, "/media/".
> > > > > > > > > ADMIN_MEDIA_PREFIX = '/media/'
>
> > > > > > > > > # List of callables that know how to import templates from
> > > > various
> > > > > > > > > sources.
> > > > > > > > > TEMPLATE_LOADERS = (
> > > > > > > > >    'django.template.loaders.filesystem.load_template_source',
>
> > > >  'django.template.loaders.app_directories.load_template_source',
> > > > > > > > > #     'django.template.loaders.eggs.load_template_source',
> > > > > > > > > )
>
> > > > > > > > > MIDDLEWARE_CLASSES = (
> > > > > > > > > "django.middleware.common.CommonMiddleware",
> > > > > > > > > "django.contrib.sessions.middleware.SessionMiddleware",
> > > > > > > > > "django.middleware.locale.LocaleMiddleware",
> > > > > > > > > "django.contrib.auth.middleware.AuthenticationMiddleware",
>
> > "django.contrib.flatpages.middleware.FlatpageFallbackMiddleware",
> > > > > > > > > "django.middleware.doc.XViewMiddleware",
> > > > > > > > > "threaded_multihost.middleware.ThreadLocalMiddleware",
> > > > > > > > > "satchmo_store.shop.SSLMiddleware.SSLRedirect")
>
> > > > > > > > > ROOT_URLCONF = 'artvswall.urls'
>
> > > > > > > > > TEMPLATE_DIRS = (os.path.join(DIRNAME, "templates"))
>
> > > > > > > > > TEMPLATE_CONTEXT_PROCESSORS =
> > > > > > > > > ('satchmo_store.shop.context_processors.settings',
>
> ...
>
> read more »

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

Reply via email to