[GH-ISSUE #734] u'modoboa_admin' is not a registered namespace #671

Closed
opened 2026-02-27 11:12:57 +03:00 by kerem · 8 comments
Owner

Originally created by @workino on GitHub (May 29, 2015).
Original GitHub issue: https://github.com/modoboa/modoboa/issues/734

Hello,
i'm trying to figure out how to solve this issue but no lucky.

/usr/local/lib/python2.7/dist-packages/modoboa/core/views/auth.py in dologin
nextlocation = request.POST.get("next", None)
if nextlocation is None or nextlocation == "None":
if user.group == "SimpleUsers":
nextlocation = reverse("topredirection")
else:
# FIXME
nextlocation = reverse("modoboa_admin:domain_list") ...
return HttpResponseRedirect(nextlocation)
error = _(
"Your username and password didn't match. Please try again.")
logger.warning(
"Failed connection attempt from '%(addr)s' as user '%(user)s'"
% {"addr": request.META["REMOTE_ADDR"],

Originally created by @workino on GitHub (May 29, 2015). Original GitHub issue: https://github.com/modoboa/modoboa/issues/734 Hello, i'm trying to figure out how to solve this issue but no lucky. /usr/local/lib/python2.7/dist-packages/modoboa/core/views/auth.py in dologin nextlocation = request.POST.get("next", None) if nextlocation is None or nextlocation == "None": if user.group == "SimpleUsers": nextlocation = reverse("topredirection") else: # FIXME nextlocation = reverse("modoboa_admin:domain_list") ... return HttpResponseRedirect(nextlocation) error = _( "Your username and password didn't match. Please try again.") logger.warning( "Failed connection attempt from '%(addr)s' as user '%(user)s'" % {"addr": request.META["REMOTE_ADDR"],
kerem closed this issue 2026-02-27 11:12:57 +03:00
Author
Owner

@tonioo commented on GitHub (May 30, 2015):

Hi,
have you installed the modoboa-admin package ?

<!-- gh-comment-id:107017162 --> @tonioo commented on GitHub (May 30, 2015): Hi, have you installed the modoboa-admin package ?
Author
Owner

@stepps commented on GitHub (Jul 3, 2015):

I am having the same issue but I have installed modoboa-admin with pip

sudo pip install modoboa-admin
Requirement already satisfied (use --upgrade to upgrade): modoboa-admin in /usr/lib/python2.7/site-packages
Requirement already satisfied (use --upgrade to upgrade): modoboa>=1.3.2 in /usr/lib/python2.7/site-packages (from modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): rfc6266 in /usr/lib/python2.7/site-packages (from modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): progressbar==2.3 in /usr/lib/python2.7/site-packages (from modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): django>=1.7,<1.8 in /usr/lib64/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): django-reversion==1.8.5 in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): dj-database-url in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): pycrypto in /usr/lib64/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): argparse in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): factory-boy>=2.4 in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): passlib in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): django-versionfield2>=0.3.3 in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): requests in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): django-xforwardedfor-middleware in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin)
Requirement already satisfied (use --upgrade to upgrade): LEPL in /usr/lib/python2.7/site-packages (from rfc6266->modoboa-admin)
Cleaning up...

<!-- gh-comment-id:118429899 --> @stepps commented on GitHub (Jul 3, 2015): I am having the same issue but I have installed modoboa-admin with pip sudo pip install modoboa-admin Requirement already satisfied (use --upgrade to upgrade): modoboa-admin in /usr/lib/python2.7/site-packages Requirement already satisfied (use --upgrade to upgrade): modoboa>=1.3.2 in /usr/lib/python2.7/site-packages (from modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): rfc6266 in /usr/lib/python2.7/site-packages (from modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): progressbar==2.3 in /usr/lib/python2.7/site-packages (from modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): django>=1.7,<1.8 in /usr/lib64/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): django-reversion==1.8.5 in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): dj-database-url in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): pycrypto in /usr/lib64/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): argparse in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): factory-boy>=2.4 in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): passlib in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): django-versionfield2>=0.3.3 in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): requests in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): django-xforwardedfor-middleware in /usr/lib/python2.7/site-packages (from modoboa>=1.3.2->modoboa-admin) Requirement already satisfied (use --upgrade to upgrade): LEPL in /usr/lib/python2.7/site-packages (from rfc6266->modoboa-admin) Cleaning up...
Author
Owner

@tonioo commented on GitHub (Jul 4, 2015):

A full python stacktrace would be helpful...

<!-- gh-comment-id:118471223 --> @tonioo commented on GitHub (Jul 4, 2015): A full python stacktrace would be helpful...
Author
Owner

@thoastbrot commented on GitHub (Jul 7, 2015):

Same problem here, pip install'ed modoboa modoboa-webmail modoboa-admin:

Ran python manage.py runserver 0.0.0.0:9090 with debug enabled and pointed a browser to the url:

Environment:

Request Method: GET
Request URL: http://my.configured.host:9090/

Django Version: 1.7.8
Python Version: 2.7.9
Installed Applications:
('django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.sites',
'django.contrib.staticfiles',
'reversion',
'modoboa',
'modoboa.core',
'modoboa.lib')
Installed Middleware:
('x_forwarded_for.middleware.XForwardedForMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.locale.LocaleMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
'modoboa.lib.middleware.AjaxLoginRedirect',
'modoboa.lib.middleware.CommonExceptionCatcher',
'modoboa.lib.middleware.RequestCatcherMiddleware')

Traceback:
File "/home/modoboa/venv/local/lib/python2.7/site-packages/django/core/handlers/base.py" in get_response

  1.                 response = wrapped_callback(request, _callback_args, *_callback_kwargs)
    
    File "/home/modoboa/venv/local/lib/python2.7/site-packages/django/db/transaction.py" in inner
  2.             return func(_args, *_kwargs)
    
    File "/home/modoboa/venv/local/lib/python2.7/site-packages/django/contrib/auth/decorators.py" in _wrapped_view
  3.             return view_func(request, _args, *_kwargs)
    
    File "/home/modoboa/venv/local/lib/python2.7/site-packages/modoboa/lib/web_utils.py" in topredirection
  4.     path = reverse("modoboa_admin:domain_list")
    
    File "/home/modoboa/venv/local/lib/python2.7/site-packages/django/core/urlresolvers.py" in reverse
  5.                                      key)
    

Exception Type: NoReverseMatch at /
Exception Value: u'modoboa_admin' is not a registered namespace

<!-- gh-comment-id:119089758 --> @thoastbrot commented on GitHub (Jul 7, 2015): Same problem here, pip install'ed modoboa modoboa-webmail modoboa-admin: Ran `python manage.py runserver 0.0.0.0:9090` with debug enabled and pointed a browser to the url: Environment: Request Method: GET Request URL: http://my.configured.host:9090/ Django Version: 1.7.8 Python Version: 2.7.9 Installed Applications: ('django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.sites', 'django.contrib.staticfiles', 'reversion', 'modoboa', 'modoboa.core', 'modoboa.lib') Installed Middleware: ('x_forwarded_for.middleware.XForwardedForMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'django.middleware.locale.LocaleMiddleware', 'django.middleware.clickjacking.XFrameOptionsMiddleware', 'modoboa.lib.middleware.AjaxLoginRedirect', 'modoboa.lib.middleware.CommonExceptionCatcher', 'modoboa.lib.middleware.RequestCatcherMiddleware') Traceback: File "/home/modoboa/venv/local/lib/python2.7/site-packages/django/core/handlers/base.py" in get_response 1. response = wrapped_callback(request, _callback_args, *_callback_kwargs) File "/home/modoboa/venv/local/lib/python2.7/site-packages/django/db/transaction.py" in inner 2. return func(_args, *_kwargs) File "/home/modoboa/venv/local/lib/python2.7/site-packages/django/contrib/auth/decorators.py" in _wrapped_view 3. return view_func(request, _args, *_kwargs) File "/home/modoboa/venv/local/lib/python2.7/site-packages/modoboa/lib/web_utils.py" in topredirection 4. path = reverse("modoboa_admin:domain_list") File "/home/modoboa/venv/local/lib/python2.7/site-packages/django/core/urlresolvers.py" in reverse 5. key) Exception Type: NoReverseMatch at / Exception Value: u'modoboa_admin' is not a registered namespace
Author
Owner

@tonioo commented on GitHub (Jul 7, 2015):

Please make sure you installed modoboa > 1.3 :
$ pip install modoboa==1.3.3

<!-- gh-comment-id:119101488 --> @tonioo commented on GitHub (Jul 7, 2015): Please make sure you installed modoboa > 1.3 : `$ pip install modoboa==1.3.3`
Author
Owner

@stepps commented on GitHub (Jul 7, 2015):

I had modoboa 1.3 installed. The issue apparently is that I need to run modoboa as root. It has to do with the permissions of the pip modules installed. I am not very happy to run modoboa as root, but for testing purposes it is ok.
My target is deploy modoboa and all the pip modules by rpm, because it needs to be installed in a tightly controlled environment.

<!-- gh-comment-id:119189078 --> @stepps commented on GitHub (Jul 7, 2015): I had modoboa 1.3 installed. The issue apparently is that I need to run modoboa as root. It has to do with the permissions of the pip modules installed. I am not very happy to run modoboa as root, but for testing purposes it is ok. My target is deploy modoboa and all the pip modules by rpm, because it needs to be installed in a tightly controlled environment.
Author
Owner

@tonioo commented on GitHub (Jul 7, 2015):

If you run modoboa into a virtualenv, no need to run as root.

<!-- gh-comment-id:119189728 --> @tonioo commented on GitHub (Jul 7, 2015): If you run modoboa into a virtualenv, no need to run as root.
Author
Owner

@thoastbrot commented on GitHub (Jul 7, 2015):

I figured out that my problem were the missing extensions. Also, I installed modoboa-admin after creating the site folder (which hadn't worked anyway if I had selected to install extensions).
To do anything, I had to manually append core/ to the url after logging in.

To have a "ready-to-work" service, I had to add modoboa-admin to the list of extensions. Why is that so? Why is a required package (eg view on / ) an optional package, an extension?

I also would fancy a list of available extensions, either as fixed list on the documentation or a rendered list of installed modules in the help text.

<!-- gh-comment-id:119193588 --> @thoastbrot commented on GitHub (Jul 7, 2015): I figured out that my problem were the missing extensions. Also, I installed modoboa-admin _after_ creating the site folder (which hadn't worked anyway if I had selected to install extensions). To do anything, I had to manually append core/ to the url after logging in. To have a "ready-to-work" service, I had to add modoboa-admin to the list of extensions. Why is that so? Why is a required package (eg view on / ) an optional package, an extension? I also would fancy a list of available extensions, either as fixed list on the documentation or a rendered list of installed modules in the help text.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/modoboa-modoboa#671
No description provided.