F
F
freem4n2012-07-30 14:45:08
Django
freem4n, 2012-07-30 14:45:08

What other reasons could there be for the NoReverseMatch exception to occur?

What else could be the reasons for the exception

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

when doing redirect (someview)

if:
1. all urls in urls.py are valid
2. templates are valid
3. parameters passed in urls are valid?

Read the answer below.

The second question is how to avoid a similar situation in the future?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
alz, 2012-07-30
@alz

Do you import * more often

F
freem4n, 2012-07-30
@freem4n

And immediately a lightning-fast answer:
view in redirect'e is defined twice.
For example, I have
../views/__init__.py:
from common import *
from something import *
so, I had someview in both common.py and something.py.
spent half a day looking for it.
I did not find it on the Internet.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question