mirror of
https://github.com/modoboa/modoboa.git
synced 2026-04-25 17:06:01 +03:00
[GH-ISSUE #506] Cannot resolve 'modoboa.core.loggers.SQLHandler' when updating to 1.1.0 #489
Labels
No labels
bug
bug
dependencies
design
documentation
duplicate
enhancement
enhancement
enhancement
feedback-needed
help-needed
help-needed
installer
invalid
looking-for-sponsors
modoboa-contacts
new-ui
new-ui
pr
pull-request
pyconfr
python
question
security
stale
webmail
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/modoboa-modoboa#489
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @jossensei on GitHub (Jan 3, 2014).
Original GitHub issue: https://github.com/modoboa/modoboa/issues/506
Updating from 1.0.1 to 1.1.0, I've changed the settings.py like the documentation said, I've run the commands :
pip install --upgrade modoboa
printed "Successfully installed modoboa django south lxml rfc6266 factory-boy"
Then I've run :
python manage.py syncdb
But I've got :
ValueError: Unable to configure handler 'modoboa': Cannot resolve 'modoboa.core.loggers.SQLHandler': No module named loggers
@tonioo commented on GitHub (Jan 3, 2014):
Can you try to import the SQLHandler class in a python shell like this :
from modoboa.core.loggers import SQLHandler
to see if an error occurs ?
@jossensei commented on GitHub (Jan 4, 2014):
with "from modoboa.core.loggers import SQLHandler", I get :
Traceback (most recent call last):
File "", line 1, in
ImportError: No module named loggers
with "from modoboa.lib.logutils import SQLHandler", I get :
Traceback (most recent call last):
File "", line 1, in
File "/usr/local/lib/python2.7/dist-packages/modoboa/lib/logutils.py", line 2, in
from models import Log
File "/usr/local/lib/python2.7/dist-packages/modoboa/lib/models.py", line 1, in
import reversion
File "/usr/local/lib/python2.7/dist-packages/reversion/init.py", line 11, in
from reversion.revisions import default_revision_manager, revision_context_manager, VersionAdapter
File "/usr/local/lib/python2.7/dist-packages/reversion/revisions.py", line 10, in
from django.contrib.contenttypes.models import ContentType
File "/usr/local/lib/python2.7/dist-packages/django/contrib/contenttypes/models.py", line 1, in
from django.db import models
File "/usr/local/lib/python2.7/dist-packages/django/db/init.py", line 11, in
if settings.DATABASES and DEFAULT_DB_ALIAS not in settings.DATABASES:
File "/usr/local/lib/python2.7/dist-packages/django/conf/init.py", line 53, in getattr
self._setup(name)
File "/usr/local/lib/python2.7/dist-packages/django/conf/init.py", line 46, in _setup
% (desc, ENVIRONMENT_VARIABLE))
django.core.exceptions.ImproperlyConfigured: Requested setting DATABASES, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings.
@tonioo commented on GitHub (Jan 4, 2014):
It seems you're still using old files from 1.0.1... Could you try to manually remove all modoboa related files in /usr/local/lib/python2.7/dist-packages and then reinstall modoboa ?
@jossensei commented on GitHub (Jan 4, 2014):
Solved ! I had to delete the /tmp/pip-build-root/modoboa folder to be able to install 1.1.0 instead of 1.0.1
Thanks :)
@tonioo commented on GitHub (Jan 4, 2014):
That's a good news :)