title: Django Template Reverse URL Resolution Not Working
body: <p>I have the following in my project's urls.py:</p>
  <pre><code>urlpatterns = patterns('',
  url(r'^watches/(?P&lt;object_id&gt;\d+)/$', list_detail.object_detail, watch_detail, name='watch_detail'),
   )
  </code></pre>
  <p>However, the following line in a template returns an error:</p>
  <pre><code>&lt;li&gt;&lt;a href =&quot;{% url 'watch_detail' 1 %}&quot;&gt;A link&lt;/a&gt;&lt;/li&gt;
  </code></pre>
  <p>It returns this error:</p>
  <blockquote>
  <p>NoReverseMatch at /watches/</p>
  <p>Reverse for ''watch_detail'' with arguments '(1,)' and keyword arguments '{}' not found.</p>
  </blockquote>
  <p>This confuses me a lot, because if I run &quot;manage.py shell&quot; I get the following results:</p>
  <pre><code>&gt;&gt;&gt; from django.core.urlresolvers import reverse
  &gt;&gt;&gt; reverse(&quot;watch_detail&quot;, args=(1,))
  '/watches/1/'
  &gt;&gt;&gt;
  </code></pre>
  <p>Any suggestions as to what might be wrong?</p>
  <p>Thank you.</p>