[Matplotlib-users] [Mac OS X 10.10.5] Macports install error :unknown locale: UTF-8

src10 src10 at hotmail.com
Fri Nov 6 10:37:55 EST 2015


Hi guys!
I am new to python and matplotlib.
I installed everything with macports and when I run the matplotlib test

python2.7 -c 'import matplotlib; print matplotlib.__version__,
matplotlib.__file__'

I get the following 

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File
"/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/__init__.py",
line 1131, in <module>
    rcParams = rc_params()
  File
"/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/__init__.py",
line 975, in rc_params
    return rc_params_from_file(fname, fail_on_error)
  File
"/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/__init__.py",
line 1100, in rc_params_from_file
    config_from_file = _rc_params_in_file(fname, fail_on_error)
  File
"/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/__init__.py",
line 1018, in _rc_params_in_file
    with _open_file_or_url(fname) as fd:
  File
"/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/contextlib.py",
line 17, in __enter__
    return self.gen.next()
  File
"/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/matplotlib/__init__.py",
line 1000, in _open_file_or_url
    encoding = locale.getdefaultlocale()[1]
  File
"/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/locale.py",
line 543, in getdefaultlocale
    return _parse_localename(localename)
  File
"/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/locale.py",
line 475, in _parse_localename
    raise ValueError, 'unknown locale: %s' % localename
ValueError: unknown locale: UTF-8


Do you guys have any idea what is happening....I have not done enything
weards just follow simple steps to install it.

I want to use QUTIP  and the matplotlib is essential for it...please if
someone know it would be really nice


thanks!
regards,








--
View this message in context: http://matplotlib.1069221.n5.nabble.com/Mac-OS-X-10-10-5-Macports-install-error-unknown-locale-UTF-8-tp46395.html
Sent from the matplotlib - users mailing list archive at Nabble.com.


More information about the Matplotlib-users mailing list