On 06/28/2010 01:55 AM, Gaëtan de Menten wrote:
On Sun, 2010-06-27 at 07:22 -0700, laurentF wrote:
I send it back because I had some problems with my cut/paste.
m.Director(name='eee')
<Director "eee">
m.Director(name=u'ééé')
Traceback (most recent call last):
File "<input>", line 1, in<module>
UnicodeEncodeError: 'ascii' codec can't encode characters in position
11-20: ordinal not in range(128)
Ah, that's more understandable than your previous code (and this error
has nothing to do with Elixir). It is most likely a python prompt (or
text editor)/string literal encoding mismatch. Try simply:
a = u'ééé'
and debug that instead...
There are tons of places on the net where you can find some info on
this. For example:
http://evanjones.ca/python-utf8.html
On Jun 27, 11:07 pm, laurentF<[email protected]> wrote:
Hy,
Not sure it's a problem of Elixir but If I use the
model:http://elixir.ematia.de/trac/attachment/wiki/TutorialDivingIn/model.py
----
import model as m
m.Director(name='')
<Director "">
m.Director(name=u'')
Traceback (most recent call last):
File "<input>", line 1, in<module>
UnicodeEncodeError: 'ascii' codec can't encode characters in position
11-20: ordinal not in range(128)
----
If someone can explain and __make me understand__
the problem with text=u''.
I have been reading a lot on unicode but doesn't help.
sys.version: '2.6.5+ (release26-maint, Jun 16 2010, 09:20:52) \n[GCC
4.4.4]'
Laurent FRANCOIS
Maybe this is not a problem with elixir.
For sure the elixir tutorial is awful with unicode.
And bring a lot of exeption with UnicodeEncodeError
Thanks
--
Laurent FRANCOIS
--
You received this message because you are subscribed to the Google Groups
"SQLElixir" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sqlelixir?hl=en.