Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > set python default encoding

Reply
Thread Tools

set python default encoding

 
 
reetesh nigam
Guest
Posts: n/a
 
      04-06-2009
Hi All,
I am unable to set the python default encoding.
i used the following proccess to set the python encoding

import sys
reload(sys)
sys.setdefaultencoding('latin-1')

but it is giving me the same error :

args = ('utf8', "MEDICINE '\xc4 ", 10, 12, 'invalid data',
<bound method Root.history of <radspeed.controllers.Root object at
0x036FFE90>>)
encoding = 'utf8'
end = 12
message = ''
object = "MEDICINE '\xc4 "
reason = 'invalid data'
start = 10


Please tell me how to solve this problem.

Thanks and Regards

Reetesh Nigam
 
Reply With Quote
 
 
 
 
R. David Murray
Guest
Posts: n/a
 
      04-06-2009
reetesh nigam <(E-Mail Removed)> wrote:
> Hi All,
> I am unable to set the python default encoding.
> i used the following proccess to set the python encoding
>
> import sys
> reload(sys)
> sys.setdefaultencoding('latin-1')
>
> but it is giving me the same error :
>
> args = ('utf8', "MEDICINE '\xc4 ", 10, 12, 'invalid data',
> <bound method Root.history of <radspeed.controllers.Root object at
> 0x036FFE90>>)
> encoding = 'utf8'
> end = 12
> message = ''
> object = "MEDICINE '\xc4 "
> reason = 'invalid data'
> start = 10
>
>
> Please tell me how to solve this problem.


That doesn't look anything like a python traceback. I'm guessing
you are using some sort of web framework? Perhaps you should
try asking in the forum for the framework.

--
R. David Murray http://www.bitdance.com

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
String default encoding: UTF-16 or Platform's default charset? cs_professional Java 14 12-12-2010 06:10 PM
How to set default encoding for print? kj Python 2 01-31-2010 04:28 PM
Gridview encoding, or how to run commands before gridview's default databinding, or, how do I disable default databinding at all? Sergei Shelukhin ASP .Net 1 11-12-2006 01:43 PM
VS2005 : how do you set DEFAULT encoding of cs files to UTF-8 ? Michel de Becdelièvre ASP .Net 3 03-06-2006 10:21 PM
Encoding.Default and Encoding.UTF8 Hardy Wang ASP .Net 5 06-09-2004 04:04 PM



Advertisments