title: NoReverseMatch django - not a valid view function or pattern
body: <p>Currently using Django 1.11. I get an exception of </p>
  
  <pre><code>Reverse for 'book_details' not found. 'book_details' is not a valid view function or pattern name.
  Request Method: GET
  Request URL:    http://localhost:8000/library/book/c7311ecf-eba7-4e9d-8b1a-8ba4e075245a/
  Django Version: 1.11
  Exception Type: NoReverseMatch
  </code></pre>
  
  <p>I want to use the <code>get_absolute_url</code> from my Model in the details page to go to a Update page.  When I take out the reference to the .id and use the get_absolute_url.  I checked to see the name "book_details" is referenced properly. I can go to the page and have books details render properly. In the admin console of Django, the "view on site" button also does not render properly it shows this localhost:8000/admin/r/13/c7311ecf-eba7-4e9d-8b1a-8ba4e075245a/  so it does not get the library/books either</p>
  
  <p>current
  <code>&lt;a href =" {{ book.id }}/update"&gt;Update&lt;/a&gt;</code></p>
  
  <p>desired
  <code>&lt;a href =" {{ book.get_absolute_url }}/update"&gt;Update&lt;/a&gt;</code></p>
  
  <p>Where have I mistyped for this to not work?</p>
  
  <hr>
  
  <p>Setup in files:</p>
  
  <p>Yes, I do have UUID as the primary key.</p>
  
  <p>In <code>views.py</code></p>
  
  <pre><code>class BookDetailsView(generic.DetailView):
  """
  Generic class-based detail view for a Book.
  """
  model = Book
  </code></pre>
  
  <p>in <code>urls.py</code></p>
  
  <pre><code>url(r'^book/(?P&lt;pk&gt;[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})$', views.BookDetailsView.as_view(), name='book_details'),
  url(r'^book/(?P&lt;pk&gt;[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})/update/$', views.BookUpdate.as_view(), name='book_update'),
  </code></pre>
  
  <p>in <code>models.py</code></p>
  
  <p>class Book(models.Model):</p>
  
  <pre><code>def get_absolute_url(self):
      """Returns the URL of the book for details"""
      return reverse('book_details', args=[str(self.id)])
  </code></pre>