title: Flask Datetime: UnboundLocalError: local variable 'date' referenced before assignment
body: <p>I'm having troubles with flask.</p>
  <pre><code>@productivity.route('/productivity', methods=['GET', 'POST'])
  @login_required
  def productivity_view():
      today = date.today()
  </code></pre>
  <p>I get this error: UnboundLocalError: local variable 'date' referenced before assignment.</p>
  <p>What can I do?</p>