<commit_before>from flask.ext.wtf import Form, TextField, FloatField, Required, SelectField
from wtforms.ext.dateutil.fields import DateField

class TypeForm(Form):
    name = TextField('Name', [Required()])
    unit = TextField('Unit', [Required()])

class EventForm(Form):
    symbol = TextField('Symbol', description='Stock ticker symbol')
    type_id = SelectField('Type', description='Type of event', coerce=int)
    value = FloatField('Value', description='Amount the event was worth')
    date = DateField(u'Date', description='Date the event happened')
<commit_msg>Beef up forms<commit_after>from flask.ext.wtf import Form, TextField, FloatField, Required, SelectField
from wtforms.ext.dateutil.fields import DateField

class TypeForm(Form):
    name = TextField('Type Name', description='Type of event', validators=[Required()])
    unit = TextField('Unit', description='Unit of measurement', validators=[Required()])

class EventForm(Form):
    symbol = TextField('Symbol', description='Stock ticker symbol',
    	validators=[Required()])
    type_id = SelectField('Type', description='Type of event', coerce=int,
    	validators=[Required()])
    value = FloatField('Value', description='Amount the event was worth',
    	validators=[Required()])
    date = DateField('Date', description='Date the event happened',
    	validators=[Required()])

{'fraction_non_alphanumeric': 0.13716814159292035, 'fraction_numerical': 0.0, 'mean_word_length': 5.785, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '466671', 'n_tokens_mistral': 379, 'n_tokens_neox': 370, 'n_words': 105}