runserver error

127 views
Skip to first unread message

Swathi Rajanna

unread,
Sep 2, 2014, 4:41:47 PM9/2/14
to django...@googlegroups.com
python manage.py runserver
Traceback (most recent call last):
  File "manage.py", line 11, in <module>
    execute_from_command_line(sys.argv)
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 399, in execute_from_command_line
    utility.execute()
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 392, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/core/management/base.py", line 242, in run_from_argv
    self.execute(*args, **options.__dict__)
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/core/management/base.py", line 280, in execute
    translation.activate('en-us')
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/utils/translation/__init__.py", line 130, in activate
    return _trans.activate(language)
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/utils/translation/trans_real.py", line 188, in activate
    _active.value = translation(language)
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/utils/translation/trans_real.py", line 177, in translation
    default_translation = _fetch(settings.LANGUAGE_CODE)
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/utils/translation/trans_real.py", line 159, in _fetch
    app = import_module(appname)
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/utils/importlib.py", line 40, in import_module
    __import__(name)
ImportError: No module named password_reset

Collin Anderson

unread,
Sep 2, 2014, 4:44:12 PM9/2/14
to django...@googlegroups.com
don't use quotes in your url conf:

from whatever import password_reset

url
(r'^reset_password/$', password_reset),

# not this
url
(r'^reset_password/$', "password_reset"),

Swathi Rajanna

unread,
Sep 2, 2014, 5:27:34 PM9/2/14
to django...@googlegroups.com
gave*


On Wed, Sep 3, 2014 at 2:57 AM, Swathi Rajanna <swathi...@gmail.com> wrote:

    (r'^resetpassword/passwordsent/$',django.contrib.auth.views.password_reset_done),
    (r'^resetpassword/$',django.contrib.auth.views.password_reset),
    #(r'^reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$','django.contrib.auth.views.password_reset_confirm'),
    url(r'^reset/(?P<uidb64>[0-9A-Za-z_\-]+)/(?P<token>[0-9A-Za-z]{1,13}-[0-9A-Za-z]{1,20})/$',
    django.contrib.auth.views.password_reset_confirm),
    (r'^reset/done/$',django.contrib.auth.views.password_reset_complete),

 this is what i GAVE


--
You received this message because you are subscribed to a topic in the Google Groups "Django users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/django-users/Si2Vm9BZ2Jo/unsubscribe.
To unsubscribe from this group and all its topics, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/adddcf9f-6dbf-46c1-abd7-6fa84b113404%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.


Swathi Rajanna

unread,
Sep 2, 2014, 5:27:34 PM9/2/14
to django...@googlegroups.com

    (r'^resetpassword/passwordsent/$',django.contrib.auth.views.password_reset_done),
    (r'^resetpassword/$',django.contrib.auth.views.password_reset),
    #(r'^reset/(?P<uidb36>[0-9A-Za-z]+)-(?P<token>.+)/$','django.contrib.auth.views.password_reset_confirm'),
    url(r'^reset/(?P<uidb64>[0-9A-Za-z_\-]+)/(?P<token>[0-9A-Za-z]{1,13}-[0-9A-Za-z]{1,20})/$',
    django.contrib.auth.views.password_reset_confirm),
    (r'^reset/done/$',django.contrib.auth.views.password_reset_complete),

 this is what i GAVE
On Wed, Sep 3, 2014 at 2:14 AM, Collin Anderson <cmawe...@gmail.com> wrote:

--
You received this message because you are subscribed to a topic in the Google Groups "Django users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/django-users/Si2Vm9BZ2Jo/unsubscribe.
To unsubscribe from this group and all its topics, send an email to django-users...@googlegroups.com.
To post to this group, send email to django...@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.

Swathi Rajanna

unread,
Sep 3, 2014, 2:13:39 AM9/3/14
to django...@googlegroups.com
I added password_reset import to /home/swathi/env/local/lib/python2.7/site-packages/django/utils/importlib.py
 then I got this
 python manage.py runserver
Traceback (most recent call last):
  File "manage.py", line 9, in <module>
    from django.core.management import execute_from_command_line
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 10, in <module>
    from django.utils.importlib import import_module
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/utils/importlib.py", line 5, in <module>
    from django.contrib.auth.views import password_reset, password_reset_confirm
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/contrib/auth/__init__.py", line 3, in <module>
    from django.conf import settings
  File "/home/swathi/env/local/lib/python2.7/site-packages/django/conf/__init__.py", line 18, in <module>
    from django.utils import importlib
ImportError: cannot import name importlib
 
Reply all
Reply to author
Forward
0 new messages