Failed to set locale #872

Closed
opened 2016-06-14 20:36:05 +02:00 by ghost · 6 comments
ghost commented 2016-06-14 20:36:05 +02:00 (Migrated from github.com)

Hi, while running the latest master branch, I encountered the following error:

ERROR - Failed to set locale to en_US.ISO8859-1

A quick lookup with locale -a showed that my system has many locales, but none matching the required one. Although a bit weird, as the line, causing the error, namely:

pythonlocale.setlocale(pythonlocale.LC_ALL, lang)

is calling only pythonlocale.LC_ALL which eventually is turned into en_US.ISO8859-1 by Python's locale.py. So is it a Python-and-my-system-related bug or somewhat else, like a PyQT issue?

Hi, while running the latest master branch, I encountered the following error: ``` ERROR - Failed to set locale to en_US.ISO8859-1 ``` A quick lookup with `locale -a` showed that my system has many locales, but none matching the required one. Although a bit weird, as the line, causing the error, namely: ``` python pythonlocale.setlocale(pythonlocale.LC_ALL, lang) ``` is calling only `pythonlocale.LC_ALL` which eventually is turned into `en_US.ISO8859-1` by Python's `locale.py`. So is it a Python-and-my-system-related bug or somewhat else, like a PyQT issue?
PeterSurda commented 2016-06-14 20:55:34 +02:00 (Migrated from github.com)

Hi,

this is a known bug (it does not try UTF-8 but defaults to the default locale encoding), I just haven't opened a ticket yet. You can work around it in the meantime by using locale-gen to generate the locale that's missing.

Hi, this is a known bug (it does not try UTF-8 but defaults to the default locale encoding), I just haven't opened a ticket yet. You can work around it in the meantime by using locale-gen to generate the locale that's missing.
ghost commented 2016-06-14 21:08:38 +02:00 (Migrated from github.com)

@PeterSurda May I ask why we aren't trying to load UTF-8? I guess because of compatibility issues with specific chars? It would be far more universal if there UTF-8 (or maybe even UTF-16) would be used.

@PeterSurda May I ask why we aren't trying to load UTF-8? I guess because of compatibility issues with specific chars? It would be far more universal if there UTF-8 (or maybe even UTF-16) would be used.
PeterSurda commented 2016-06-14 21:11:50 +02:00 (Migrated from github.com)

I fixed a bug and that opened a new one. I'll fix this one too, don't worry.

I fixed a bug and that opened a new one. I'll fix this one too, don't worry.
ghost commented 2016-06-14 21:16:46 +02:00 (Migrated from github.com)

I'm not worrying, I'm here to help 😄

I'm not worrying, I'm here to help :smile:
PeterSurda commented 2016-06-14 21:59:59 +02:00 (Migrated from github.com)

Please retry with the latest v0.6 branch and close if it's fixed. It will still complain but it will then try UTF-8 and that should succeed.

Please retry with the latest v0.6 branch and close if it's fixed. It will still complain but it will then try UTF-8 and that should succeed.
ghost commented 2016-06-14 22:29:40 +02:00 (Migrated from github.com)

It works now. At least it didn't throw any errors regarding locale.

It works now. At least it didn't throw any errors regarding locale.
This repo is archived. You cannot comment on issues.
No Milestone
No project
No Assignees
1 Participants
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: Bitmessage/PyBitmessage-2024-12-18#872
No description provided.