Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unsupported locale on Windows ... #1

Open
hannesrauhe opened this issue Aug 5, 2014 · 11 comments
Open

Unsupported locale on Windows ... #1

hannesrauhe opened this issue Aug 5, 2014 · 11 comments

Comments

@hannesrauhe
Copy link
Collaborator

[  ERROR] Error reading lunch menus
Traceback (most recent call last):
  File "C:/Users/d054203/.lunchinator/eurest-lunch-menu\eurest_lunch_menu\__init__.py", line 137, in initialize
    locale.setlocale(locale.LC_TIME, (cls.defaultLocaleString,"UTF-8"))
  File "C:\Python27_64\lib\locale.py", line 547, in setlocale
    return _setlocale(category, locale)
Error: unsupported locale setting
@entropia1
Copy link
Owner

I have no idea how locales work on Windows and I have no possibility to test ;-)

@hannesrauhe
Copy link
Collaborator Author

print cls.defaultLocaleString says: de_DE

@hannesrauhe
Copy link
Collaborator Author

It's a pitty, since the old lunch menu URL is not there anymore :-(

@entropia1
Copy link
Owner

defaultLocaleString is hard coded by me, right? I guess locale doesn't work at all on Windows (the documentation says something about POSIX systems) and we have to do something completely differently here.

@hannesrauhe
Copy link
Collaborator Author

@hannesrauhe
Copy link
Collaborator Author

I look into it. The stackoverflow thread seems to be misleading.

I think, the problem is utf-8...

@entropia1
Copy link
Owner

Seems that this is the most urgent feature request currently; do you know anything by now?

@hannesrauhe
Copy link
Collaborator Author

I juggled a bit with the locales but wasn't able to get anything to work...

@entropia1
Copy link
Owner

OK, I guess then I just disable all locale stuff on Windows for now. As far as I remember, I only need it for the translated UI.

entropia1 pushed a commit that referenced this issue Aug 20, 2014
@entropia1
Copy link
Owner

Can you please re-check?

@hannesrauhe
Copy link
Collaborator Author

2014-08-20 10:43:34,976 - ERROR - Error reading lunch menus
Traceback (most recent call last):
  File "C:/Users/d054203/.lunchinator/eurest-lunch-menu\eurest_lunch_menu\__init__.py", line 137, in initialize
    cls._lunchMenus, cls._additives = cls.readLunchMenus(cls.defaultLocaleString, cls._messages)
ValueError: too many values to unpack

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants