title: Python enconding with mysql
body: <p>I'm using an Active Record called <a href="http://code.activestate.com/recipes/496905-an-activerecord-like-orm-object-relation-mapper-un/" rel="nofollow">Storm</a>  in my Python code to retrieve some records on a MySQL database. </p>
  
  <p>The problem is: My table is in 'utf8_unicode_ci', but when I retrieve the object I get 'latin-1' attributes, so I need to do object.attr.decode('latin-1').encode('utf-8') wich isn't working always - throwing some exceptions. </p>
  
  <p>My question: This is a python behavior? a MySQL behavior? Something related to the Storm? </p>
  
  <p>The code:</p>
  
  <pre><code>Storm.conn(user=db_user,db=db_name, passwd=db_passwd)
  events = Event.select('*',status='=2',date_end='&gt;=NOW()')
  for event in events:
      now = datetime.datetime.now().strftime("%Y-%m-%d %H:%M")
      try:
          #here we need only utf-8 strings
          conn.index({"title": event.get_title(), "local": event.get_local(), "url": event.getUrl(), "description": event.get_description(), "artists": event.get_artists(), "tags": event.get_tags(), "picture": event.get_Picture(), "type": event.get_type(), 'date_begin': event.get_date_begin(), 'date_end': event.get_date_end(), '_ttl': event.get_ttl()}, "wf", "event", event.id)
          print 'Indexed - '+now+': '+str(event.id)
      except Exception,error:
          print 'Error - '+now+': '+str(event.id)+" - "+str(error)
  </code></pre>