title: Django TypeError at /polls/1/vote/ _reverse_with_prefix() argument after * must be an iterable, not int
body: <p>This is the polls app tutorial from the <a href="https://docs.djangoproject.com/en/2.0/intro/tutorial04/" rel="nofollow noreferrer">Django Docs</a>.  </p>
  
  <p>When I go to the first question <a href="http://127.0.0.1:8000/polls/1/" rel="nofollow noreferrer">http://127.0.0.1:8000/polls/1/</a>, select an option and click 'Vote', I get the error message.</p>
  
  <p><a href="https://i.stack.imgur.com/LYDqw.png" rel="nofollow noreferrer">error message</a></p>
  
  <p>views.py:</p>
  
  <pre><code>from django.http import HttpResponseRedirect
  from django.shortcuts import get_object_or_404, render
  from django.urls import reverse
  from django.views import generic
  
  from .models import Choice, Question
  
  
  class IndexView(generic.ListView):
      template_name = 'polls/index.html'
      context_object_name = 'latest_question_list'
  
      def get_queryset(self):
          """Return the last five published questions."""
          return Question.objects.order_by('-pub_date')[:5]
  
  
  class DetailView(generic.DetailView):
      model = Question
      template_name = 'polls/detail.html'
  
  
  class ResultsView(generic.DetailView):
      model = Question
      template_name = 'polls/results.html'
  
  
  def vote(request, question_id):
      question = get_object_or_404(Question, pk=question_id)
      try:
          # request.POST['choice'] returns ID of the selected choice as a string
          selected_choice = question.choice_set.get(pk=request.POST['choice'])
      except (KeyError, Choice.DoesNotExist):
          # Redisplay the question voting form.
          return render(request, 'polls/detail.html', {
              'question': question,
              'error_message': "You didn't select a choice.",
          })
      else:
          selected_choice.votes += 1
          selected_choice.save()
          # Always return a HttpResponseRedirect after successfully dealing with POST data.
          # This prevents the data from being posted twice if a user hits the Back button.
          return HttpResponseRedirect(reverse('polls:results', args=question_id, ))
  </code></pre>
  
  <p>polls/urls.py:</p>
  
  <pre><code>from django.urls import path
  
  from . import views
  
  app_name = 'polls'
  urlpatterns = [
      path('', views.IndexView.as_view(), name='index'),
      path('&lt;int:pk&gt;/', views.DetailView.as_view(), name='detail'),
      path('&lt;int:pk&gt;/results/', views.ResultsView.as_view(), name='results'),
      path('&lt;int:question_id&gt;/vote/', views.vote, name='vote'),
  ]
  </code></pre>
  
  <p>polls/templates/polls/index.html:</p>
  
  <pre><code>{% if latest_question_list %}
      &lt;ul&gt;
          {% for question in latest_question_list %}
              &lt;li&gt;&lt;a href="{% url 'polls:detail' question.id %}"&gt;{{ question.question_text }}&lt;/a&gt;&lt;/li&gt;
          {% endfor %}
      &lt;/ul&gt;
  {% else %}
      &lt;p&gt;No polls are available.&lt;/p&gt;
  {% endif %}
  </code></pre>
  
  <p>polls/templates/polls/detail.html:</p>
  
  <pre><code>&lt;h1&gt;{{ question.question_text }}&lt;/h1&gt;
  
  {% if error_message %}&lt;p&gt;&lt;strong&gt;{{ error_message }}&lt;/strong&gt;&lt;/p&gt;{% endif %}
  
  &lt;form action="{% url 'polls:vote' question.id %}" method="post"&gt;
      {% csrf_token %}
      {% for choice in question.choice_set.all %}
          &lt;input type="radio" name="choice" id="choice{{ forloop.counter }}" value="{{ choice.id }}"/&gt;
          &lt;label for="choice{{ forloop.counter }}"&gt;{{ choice.choice_text }}&lt;/label&gt;&lt;br&gt;
      {% endfor %}
      &lt;input type="submit" value="Vote"/&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p>polls/templates/polls/results.html:</p>
  
  <pre><code>&lt;h1&gt;{{ question.question_text }}&lt;/h1&gt;
  
  &lt;ul&gt;
      {% for choice in question.choice_set.all %}
          &lt;li&gt;{{ choice.choice_text }} -- {{ choice.votes }} vote{{ choice.votes|pluralize }}&lt;/li&gt;
      {% endfor %}
  &lt;/ul&gt;
  
  &lt;a href="{% url 'polls:detail' question.id %}"&gt;Vote again?&lt;/a&gt;
  </code></pre>
  
  <p>Can anyone please help?</p>