[Numpy-discussion] f2py and pygtk on windows
Sat Mar 24 09:09:45 CDT 2012
On 24 March 2012 13:28, David Froger <firstname.lastname@example.org> wrote:
> I've had similar problem in the past (but on Gnu/Linux), which was solve
> to by setting the LC_ALL environnement variable to C. (never undersant why).
> (with Bash: export LC_ALL=C)
This rings a bell. I have a feeling importing pygtk can change the
Python default encoding (sys.getdefaultencoding()). That's never
normally changed, so Python 2 code can assume it's always ascii. I
guess pygtk sets the encoding from the system locale, so if it's set
to C, it will use ascii, and the problem won't appear.
More information about the NumPy-Discussion