Ok, I'm using a virtualenv where I've installed mezzanine and sphinx.
The SECRET_KEY value is in an environment variable within the virtualenv.

I'm getting the same error message, see log attached




2014-03-07 22:02 GMT+01:00 Stephen McDonald <[email protected]>:

> Django gets loaded so that we can retrieve all of Mezzanine's settings
> (mezzanine.conf), which each contain names and descriptions - these are
> then used to generate the settings docs here:
> http://mezzanine.jupo.org/docs/configuration.html
>
> You can't load Django without SECRET_KEY defined.
>
>
> On Sat, Mar 8, 2014 at 4:38 AM, Federico Bruni <[email protected]> wrote:
>
>> Hi Ken
>>
>> I thought that building the docs was indipendent from starting a
>> mezzanine project. That's why I'm not using a virtualenv in this case.
>> My goal is being able to test a doc patch about deployment, in case I
>> manage to write something reasonable.
>> Il 07/mar/2014 18:13 "Ken Bolton" <[email protected]> ha scritto:
>>
>>>  Hi Federico,
>>>
>>> ALLOWED_HOSTS, TIME_ZONE, and SECRET_KEY do not have values. Make sure
>>> you have those set in your settings.py or local_settings.py.
>>>
>>> Backing up a moment, we see that Mezzanine is installed in
>>> /usr/local/lib/python2.7/dist-packages/. I urge you to follow the
>>> recommendations of
>>> http://effectivedjango.com/tutorial/getting-started.html and install
>>> Django, Mezzanine, and other applications in a virtualenv (
>>> http://www.virtualenv.org/en/latest/).
>>>
>>> hth,
>>> ken
>>>
>>>
>>> On Fri, Mar 7, 2014 at 12:03 PM, Federico Bruni <[email protected]>wrote:
>>>
>>>> I've tried building the docs but I'm getting this error:
>>>>
>>>> $ sphinx-build -b html docs docs/build
>>>> Running Sphinx v1.2
>>>> /usr/local/lib/python2.7/dist-packages/mezzanine/utils/conf.py:51:
>>>> UserWarning: You haven't defined the ALLOWED_HOSTS settings, which Django
>>>> 1.5 requires. Will fall back to the domains configured as sites.
>>>>   warn("You haven't defined the ALLOWED_HOSTS settings, which "
>>>> /usr/local/lib/python2.7/dist-packages/mezzanine/utils/conf.py:59:
>>>> UserWarning: TIME_ZONE setting is not set, using closest match: Europe/Rome
>>>>   warn("TIME_ZONE setting is not set, using closest match: %s" % tz)
>>>>
>>>> Exception occurred:
>>>>   File "/usr/lib/python2.7/dist-packages/django/conf/__init__.py", line
>>>> 151, in __init__
>>>>     raise ImproperlyConfigured("The SECRET_KEY setting must not be
>>>> empty.")
>>>> ImproperlyConfigured: The SECRET_KEY setting must not be empty.
>>>> The full traceback has been saved in /tmp/sphinx-err-sEgI9d.log, if you
>>>> want to report the issue to the developers
>>>>
>>>> Find attached the full log.
>>>>
>>>>  --
>>>> You received this message because you are subscribed to the Google
>>>> Groups "Mezzanine Users" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send
>>>> an email to [email protected].
>>>> For more options, visit https://groups.google.com/d/optout.
>>>>
>>>
>>>  --
>>> You received this message because you are subscribed to a topic in the
>>> Google Groups "Mezzanine Users" group.
>>> To unsubscribe from this topic, visit
>>> https://groups.google.com/d/topic/mezzanine-users/Q7rneOzrv8o/unsubscribe
>>> .
>>> To unsubscribe from this group and all its topics, send an email to
>>> [email protected].
>>>
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Mezzanine Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected].
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> Stephen McDonald
> http://jupo.org
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Mezzanine Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/mezzanine-users/Q7rneOzrv8o/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> [email protected].
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Mezzanine Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.
# Sphinx version: 1.2.2
# Python version: 2.7.6
# Docutils version: 0.11 release
# Jinja2 version: 2.7.2
# Loaded extensions:
Traceback (most recent call last):
  File "/home/fede/.virtualenvs/mezzanine-doc/local/lib/python2.7/site-packages/sphinx/cmdline.py", line 253, in main
    warningiserror, tags, verbosity, parallel)
  File "/home/fede/.virtualenvs/mezzanine-doc/local/lib/python2.7/site-packages/sphinx/application.py", line 107, in __init__
    confoverrides or {}, self.tags)
  File "/home/fede/.virtualenvs/mezzanine-doc/local/lib/python2.7/site-packages/sphinx/config.py", line 229, in __init__
    execfile_(filename, config)
  File "/home/fede/.virtualenvs/mezzanine-doc/local/lib/python2.7/site-packages/sphinx/util/pycompat.py", line 105, in execfile_
    exec code in _globals
  File "conf.py", line 26, in <module>
  File "/home/fede/.virtualenvs/mezzanine-doc/local/lib/python2.7/site-packages/mezzanine/utils/docs.py", line 26, in <module>
    from mezzanine.conf import registry
  File "/home/fede/.virtualenvs/mezzanine-doc/local/lib/python2.7/site-packages/mezzanine/conf/__init__.py", line 194, in <module>
    for app in sorted(django_settings.INSTALLED_APPS, key=mezz_first):
  File "/home/fede/.virtualenvs/mezzanine-doc/local/lib/python2.7/site-packages/django/conf/__init__.py", line 54, in __getattr__
    self._setup(name)
  File "/home/fede/.virtualenvs/mezzanine-doc/local/lib/python2.7/site-packages/django/conf/__init__.py", line 49, in _setup
    self._wrapped = Settings(settings_module)
  File "/home/fede/.virtualenvs/mezzanine-doc/local/lib/python2.7/site-packages/django/conf/__init__.py", line 151, in __init__
    raise ImproperlyConfigured("The SECRET_KEY setting must not be empty.")
ImproperlyConfigured: The SECRET_KEY setting must not be empty.

Reply via email to