[google-appengine] Re: Unicode Support for Python 2.5

2011-07-08 Thread prakhil samar
Hey is there anyone GAE expert to resolve this issue I m stucked over this and need to resolve this ASAP. Thanks On Jul 5, 11:34 am, prakhil samar prakhilsa...@gmail.com wrote: Thanks again Julian i tried the syntax that you have given, but this does not solves our problem This is the

Re: [google-appengine] Re: Unicode Support for Python 2.5

2011-07-08 Thread Branko Vukelic
Have you tried unicode(self.request.get('file1'))? There's also force_unicode function in Django. I use a simplified version of it: def force_unicode(s): if not s: return u'' if isinstance(s, unicode): return s try: return unicode(s) except: try:

[google-appengine] Re: Unicode Support for Python 2.5

2011-07-05 Thread prakhil samar
Thanks again Julian i tried the syntax that you have given, but this does not solves our problem This is the error now i m getting when i use csv_file = self.request.get('file1').decode('utf-8') Traceback (most recent call last): File

[google-appengine] Re: Unicode Support for Python 2.5

2011-07-04 Thread Julian Namaro
Prakhil, Did you resolve this ? You need to do the convertion to unicode before any split or strip, try csv_file = self.request.get('file1').decode('utf-8') on your first line or if it is urlencoded: csv_file = urllib.unquote( self.request.get('file1') ).decode('utf-8') On Jul 1, 3:45 pm,

[google-appengine] Re: Unicode Support for Python 2.5

2011-07-01 Thread T. Abilo
I had the same issue. You can avoid this issue (which is caused by your unicode wrongly being handed as a str), simply by forcing it to be unicode like u'mystring' for example. -- You received this message because you are subscribed to the Google Groups Google App Engine group. To view this