Trouble with source-code encoding

Skip Montanaro skip at pobox.com
Fri Sep 12 21:46:55 CEST 2003


    Fernando> I just upgraded to Python2.3 and I'm getting a weird warning complaining about
    Fernando> the encoding and asking me to read a pep.  OK, I read the Pep and know what
    Fernando> syntax to specify the enconding:
    Fernando> # -*- coding: <encoding name> -*-

    Fernando> However, th epep doesn't list the name of valid encodings.
    Fernando> What's the name for west european encoding?

That would be

    # -*- coding: latin1 -*-

or

    # -*- coding: iso8859-1 -*-

I believe.

Skip





More information about the Python-list mailing list