Skip to content

Commit d91d8a5

Browse files
committed
Fixes #69: Qt console encoding for frozen apps
1 parent bc64493 commit d91d8a5

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@
1111
* Added a workaround: on Windows, if locale can't be detected, we now use the
1212
Windows API to retrieve it (using the `GetUserDefaultLocaleName` function)
1313
* [Issue #68](https://github.com/PlotPyStack/guidata/issues/68) - Windows: gettext translation is not working on frozen applications
14+
* Embedded Qt console:
15+
* Fixed default encoding detection on frozen applications on Windows
16+
* [Issue #69](https://github.com/PlotPyStack/guidata/issues/69) - Windows/Qt console: output encoding is not detected on frozen applications
1417

1518
## Version 3.2.1 ##
1619

guidata/widgets/console/shell.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -615,7 +615,7 @@ def flush(self, error=False, prompt=False):
615615
except TypeError:
616616
text = b"".join(self.__buffer)
617617
try:
618-
text = text.decode(locale.getlocale()[1])
618+
text = text.decode(locale.getpreferredencoding())
619619
except:
620620
pass
621621

0 commit comments

Comments
 (0)