use text_type instead of unicode