Ho seguito con interesse la discussione: io so gestire dignitosamente l'unicode nei programmi... ma ancora non ho mai capito come si comporta ipython a riguardo:
pie...@vousci:~$ python Python 2.6.4 (r264:75706, Nov 2 2009, 14:44:17) [GCC 4.4.1] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import locale >>> locale.getpreferredencoding() 'UTF-8' >>> u=u'èà' >>> print u èà , giustamente; invece... pie...@vousci:~/cancellami$ ipython Python 2.6.4 (r264:75706, Nov 2 2009, 14:44:17) Type "copyright", "credits" or "license" for more information. IPython 0.10 -- An enhanced Interactive Python. ? -> Introduction and overview of IPython's features. %quickref -> Quick reference. help -> Python's own help system. object? -> Details about 'object'. ?object also works, ?? prints more. In [1]: import locale In [2]: locale.getpreferredencoding() Out[2]: 'UTF-8' In [3]: u=u'èà' In [4]: print u ------> print(u) èà in che encoding mi sta parlando? E soprattutto perché? Pietro _______________________________________________ Python mailing list Python@lists.python.it http://lists.python.it/mailman/listinfo/python