title: flask url parameters gives error
body: <p>I am getting the following error:</p>
  
  <blockquote>
    <p>"werkzeug.routing.BuildError: Could not build url for endpoint
    'setpassword'. Did you forget to specify values ['token']?"</p>
  </blockquote>
  
  <p>main.py:</p>
  
  <pre><code>@app.route('/setpassword/&lt;token&gt;',methods=['GET','POST'])
  def setpassword(token):
      form = PasswordForm()
      return render_template('setpassword.html',form=form, token=token)
  </code></pre>
  
  <p>setpassword.html:</p>
  
  <pre><code>{% extends "base.html" %}
  {% import "bootstrap/wtf.html" as wtf %}
  {% from '_macros.html' import hello %}
  
  {% block title %}SetPassword{% endblock %}
  {% block content %}
  {% for i in form.password.validators %}
  {{ i.message }}
  {% endfor %}
  &lt;form class="form form-horizontal " action="{{ url_for('setpassword') }}"     method=post role="form"&gt;
      {{ form.hidden_tag() }}
      {{ wtf.form_field(form.password, hiddens='True',placeholder='Enter Password') }}
      {% for e in form.password.errors %}
          &lt;span class="label label-danger" id="labelerror"&gt;{{ e }}&lt;/span&gt;
      {% endfor %}
      {{ wtf.form_field(form.confirm, class='form-control' , placeholder='Confirm Password') }}
      {{ wtf.form_field(form.submit , class='btn btn-primary btn-block' ) }}
  &lt;/form&gt;
  {% endblock %}
  </code></pre>
  
  <p>Why is this error occurring and how do I stop it occurring?</p>