No Reverse Match

Create issue
Issue #1404 new
silenceti created an issue

HI, When i'm trying to access to my app, I get this error:

File "/opt/python2.7/lib/python2.7/site-packages/django/template/defaulttags.py", line 450, in render raise e NoReverseMatch: Reverse for 'satchmo_account_info' with arguments '()' and keyword arguments '{}' not found.

Django 1.3.1 Python 2.7

Any help would be appreciated.

Comments (14)

  1. Hynek Cernoch

    1.

    You should see a diagnostic page with numbered list of approximately 35 url patterns. If you see a very much shorter list, you can have a broken main urls.py in the project.

    2.What bugs you see after satchmo_check?
    ./manage.py satchmo_check

    3. If both previous is OK, can you import this without errors?

    $ ./manage.py shell
    >>> import satchmo_store.contact.view
    
  2. silenceti reporter

    Hi Hynek,

    Thanks for your reply.

    I have the following errors:

    >>> import satchmo_store.contact.view Traceback (most recent call last): File "<console>", line 1, in <module> ImportError: No module named view

  3. Hynek Cernoch

    I'm sorry. It was selected short clipboard. It should be >>> import satchmo_store.contact.views

  4. silenceti reporter

    Ok, i do the import and no errors, then run the server and go to browser:

    " File "/opt/python2.7/lib/python2.7/site-packages/django/template/defaulttags.py", line 450, in render raise e NoReverseMatch: Reverse for 'satchmo_account_info' with arguments '()' and keyword arguments '{}' not found."

  5. silenceti reporter

    For someone who have this problem, in urls.py change this:

    urlpatterns += patterns('',

    to

    urlpatterns = patterns('',

  6. silenceti reporter

    Now I have another error:

    Reverse for 'auth_logout' with arguments '()' and keyword arguments '{}' not found.

  7. silenceti reporter

    Now I have another error:

    Reverse for 'auth_logout' with arguments '()' and keyword arguments '{}' not found.

  8. Hynek Cernoch

    Do yo see in main urls.py of your project these two lines?

    from satchmo_store.urls import urlpatterns
    # not "=" but "+="  !!!
    urlpatterns += patterns('',
    

    Didn't you modified anything in satchmo_store/urls/ or satchmo_store/*/urls.py ?

    Can you confirm what I asked in the first post paragraph 1? Or even better is to use URL
    http://localsite/accounts/some_nonsense
    and send the list what you see after:
    Using the URLconf defined in store13.urls, Django tried these URL patterns, in this order:
    The best is to send it via http://dpaste.com

  9. silenceti reporter

    Yes, i've that 2 lines!

    I don't change anything in urls.py.

    I'm using the URL: http://my.ip:8000/

    Now the Error is:

    NoReverseMatch: Reverse for 'auth_login' with arguments '()' and keyword arguments '{}' not found.

    What file do you want I put in dpaste?

  10. Hynek Cernoch

    Paste no file but output of diagnostic page you see in your browser. (if DEBUG=True in *settings.py)

    Know that NoReverseMatch auth_login is much worse than unknown satchmo_account_info (it fails earlier) and in this state it is uninteresting.

    Please create a default demo project by clonesatchmo.py and verify that it vorks. Then try urls.py from this with your app and veritfy that basic things are also ok.

    Your previous advice is wrong because by replace /+=/=/ you lost the basic patterns from
    from satchmo_store.urls import urlpatterns

  11. silenceti reporter

    I try to create a new project but have this error:

    "TemplateSyntaxError at / Invalid block tag: 'endif', expected 'empty' or 'endthumbnail' Request Method: GET Request URL: http://my.ip:8000/ Django Version: 1.3.1 Exception Type: TemplateSyntaxError Exception Value: Invalid block tag: 'endif', expected 'empty' or 'endthumbnail' Exception Location: /opt/python2.7/lib/python2.7/site-packages/django/template/base.py in invalid_block_tag, line 290 Python Executable: /usr/bin/python2.7 Python Version: 2.7.0 "

    I've tried before. but no success.

  12. Hynek Cernoch

    I copied this from your last comment source:

    TemplateSyntaxError at /
    Invalid block tag: 'endif', expected 'empty' or 'endthumbnail'
    Request Method:	GET
    Request URL:	<a href="http://my.ip:8000/">http://my.ip:8000/</a>
    Django Version:	1.3.1
    Exception Type:	TemplateSyntaxError
    Exception Value:	
    Invalid block tag: 'endif', expected 'empty' or 'endthumbnail'
    Exception Location:	/opt/python2.7/lib/python2.7/site-packages/django/template/base.py in invalid_block_tag, line 290
    Python Executable:	/usr/bin/python2.7
    Python Version:	2.7.0 "
    

    (Next time please click on the icon "Code" before you paste any multiline text.)

    Answer: You have installed uncompatible versions of templates: sorl-thumbnail v. 11 with older Satchmo 0.9.2. Please use sorl-thumbnail 11 with current satchmo 0.9.3 or sorl-thumbnail 3.2.5 with satchmo 0.9.2. This has been changed 3 days ago by https://bitbucket.org/chris1610/satchmo/changeset/612d6e045a5f and can bot be mixed together

  13. Hynek Cernoch

    OK. you provided some info. Dpasted traceback in comment #11 is a secondary traceback created after Django found an unhandled exception, found DEBUG=False, tried to display a nondiagnostic error message for normal users and failed for the second time because you created a custom handler500 based on the home page template. (That is bad because it fails if db connection fails etc.).

    You did not enabled DEBUG = True which I repeat now for the forth time. (For sure read enable diagnostic page to know other two conditions) The original error 'no reverse match satchmo_account_info' was more useful before you broke it more, as I wrote.

    Maybe follow a Django tutorial on documentation page, write an even so simple app. Then try to add a simple bug to it and a to find useful debugging information.

  14. Log in to comment