#31 "unsupported locale setting"

open
nobody
s3cmd (119)
1
2009-04-21
2009-04-21
Tim Martin
No

I installed s3cmd on a relatively clean Ubuntu 8.10 server (slicehost image). As far as I can remember the install went cleanly and it worked straight away after that. However, when I logged out of the system and logged back in some days later, running 's3cmd ls' gave the following error:

----
Problem: Error: unsupported locale setting
S3cmd: 0.9.9
Python: 2.5.2 (r252:60911, Oct 5 2008, 19:29:17) [GCC 4.3.2]

Traceback (most recent call last):
File "/usr/bin/s3cmd", line 1562, in <module>
main()
File "/usr/bin/s3cmd", line 1336, in main
preferred_encoding = locale.getpreferredencoding() or "UTF-8"
File "/usr/lib/python2.5/locale.py", line 514, in getpreferredencoding
setlocale(LC_CTYPE, "")
File "/usr/lib/python2.5/locale.py", line 478, in setlocale
return _setlocale(category, locale)
Error: unsupported locale setting
----

I expect there's something wrong with my environment, which I'm happy to debug for myself (I'm suspicious that when I added a new user to the system I maybe didn't get all the environment set correctly?). However, this seems like a common enough use case and could use having a more descriptive error message or, if possible, an internal default that would let it get by with a warning rather than bombing out.

Discussion

  • Tim Martin
    Tim Martin
    2009-04-21

    • priority: 5 --> 1
     
  • Tim Martin
    Tim Martin
    2009-04-21

    Actually, it looks like my system is totally hosed and s3cmd is just the first place I saw a manifestation of it. I'll leave this open on lowest priority in case anyone cares to make the error message neater, but otherwise I apologise for the irrelevant but report.

     
  • Comment has been marked as spam. 
    Undo

    You can see all pending comments posted by this user  here


    Anonymous
    2011-08-01

    I am having this error and server not "totally hosed", just a box running with a British Locale. Any help appreciated, hence the bump! Really need to get s3tools running on this else, else I have no back-up process working!