Will you fix it in rpclib or should i do it somewhere in my app? tnx azur
______________________________________________________________ > Od: "Burak Arslan" <[email protected]> > Komu: azurIt <[email protected]> > Dátum: 19.02.2012 15:57 > Predmet: Re: [Soap-Python] rpclib and unicode strings > > CC: [email protected] >On 02/19/12 16:54, azurIt wrote: >> Little more info: >> When i send ASCII chars, i got 'str' type but when i send unicode chars, i >> got 'unicode' type. What should i do to always get unicode? >> > >hi, > >you need to provide me with a test case to have something to discuss on. > >rpclib relies on lxml for unicode conversion when dealing with xml data. >turns out it's a little quirky: > >In [4]: a=etree.fromstring('<?xml version="1.0" >encoding="UTF-8"?><root><child>data</child></root>') > >In [5]: a[0].text >Out[5]: 'data' > >In [6]: a=etree.fromstring('<?xml version="1.0" >encoding="UTF-8"?><root><child>dataç</child></root>') > >In [7]: a[0].text >Out[7]: u'data\xe7' > >so, doing unicode(str) in >https://github.com/arskom/rpclib/blob/master/src/rpclib/model/primitive.py#L142 > >could safely fix your problem. is this ok with you? > >best, >burak > _______________________________________________ Soap mailing list [email protected] http://mail.python.org/mailman/listinfo/soap
