I am learning flask and made a small application. Now I am trying to learn `form`. I used a simple code to validate a `name` request and it should give error when the `field` remains empty. But it isn't giving one.

Main file :

```
from flask import Flask, render_template
from flask.ext.moment import Moment
from flask.ext.wtf import Form
from wtforms import StringField, SubmitField, validators

import requests
import json
from datetime import datetime

app = Flask(__name__)
app.config['SECRET_KEY'] = 'abcd'
moment = Moment(app)

class Nameform(Form):
    name = StringField("whats your name?", [validators.Required()])
    submit = SubmitField('submit')

@app.route('/')
@app.route('/index')
def index():

    api_call = requests.get('https://api.stackexchange.com/2.2/users/moderators?order=desc&sort=reputation&site=stackoverflow')  # api call to stack for user with highest scores in des order

    var_1 = json.loads(api_call.text)

    var_2 = [{'link': value['link'], 'name': value['display_name'], 'user_id': value['user_id']} for value in var_1['items']]

    return render_template('index.html', posts=var_2, current_time=datetime.utcnow())

@app.route('/user/<id>/<user_name>')
def user(id, user_name):
    print id
    api_call = requests.get('https://api.stackexchange.com//2.2/users/'+id+'/reputation?site=stackoverflow')  # api call for reputation of click user

    var_1 = json.loads(api_call.text)
    return render_template('reputation.html', result=var_1, user_name=user_name)

@app.route('/test', methods=['GET', 'POST'])
def user_form():
    name = None
    form = Nameform()
    if form.validate_on_submit():
        name = form.name.data
        form.name.data = ''
    return render_template('test_form.html', form=form, name=name)

if __name__ == '__main__':
    app.run(debug=True)

```

Template for rendering:

```
<div class="page-header">
<h1>Hello, {% if name!= None %}{{ name }}{% else %}Stranger{% endif %}!</h1>
</div>
<form method=post>
{{ form.name.label }} {{ form.name() }}
{{ form.submit() }}
</form>

```

Why it is not throwing any error? when the field remains empty