> I want add full Unicode support in my scripts. Now I have encoutered 
> theoretical
> problem with command line parameters. I can't find anything in that mater. But
> I develop solution which seems to work. Question is: Is it recommendend way to
> decode command line parameters:
> 
> lFileConfig = None
> if len(sys.argv) > 1:
>    lFileConfig = unicode(sys.argv[1], locale.getpreferredencoding())
> 
> Or maybe there is other solution?

That is the right way. Expect that decoding may fail, though - see PEP
383 how this issue will be solved in Python 3.1.

Regards,
Martni
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to