Problem is in test_logic.py at test_read_encoding_default(). This function attempt to encode this (line 3068):
test_string = UNICODE_TEST_STRING.encode(locale.getpreferredencoding())
all is fine, when locale.getpreferredencoding() is equal "cp1252" or "cp65001". But when is equal "cp1250" then error happens.
Solution could be i.e. change set of chars used by this test (line 3005) from:
BYTES_TEST_STRING = bytes(range(0x20, 0x80)) + bytes(range(0xA0, 0xFF))
to:
BYTES_TEST_STRING = bytes(range(0x20, 0x80))
But probably there are also better solutions.
What were you trying to do?
I'm trying to do "make check"
What steps did you take to trigger the issue?
What did you expect to happen?
Pass whole procedure of testing
What actually happened?
I got error:
Operating System Version
Windows 10 Home 22H2 Polish (cp1250)
Mu Version
1.2.1
Other Info
Problem is in test_logic.py at
test_read_encoding_default()
. This function attempt to encode this (line 3068):test_string = UNICODE_TEST_STRING.encode(locale.getpreferredencoding())
all is fine, when locale.getpreferredencoding() is equal "cp1252" or "cp65001". But when is equal "cp1250" then error happens. Solution could be i.e. change set of chars used by this test (line 3005) from:BYTES_TEST_STRING = bytes(range(0x20, 0x80)) + bytes(range(0xA0, 0xFF))
to:BYTES_TEST_STRING = bytes(range(0x20, 0x80))
But probably there are also better solutions.BTW: This is not same problem as https://github.com/mu-editor/mu/issues/746#
Editor Log
No response