Skip to content

test_locale: test_strcoll_with_diacritic and test_strxfrm_with_diacritic tests failing on NetBSD #124108

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

Closed
furkanonder opened this issue Sep 15, 2024 · 1 comment
Labels
3.12 only security fixes 3.13 bugs and security fixes 3.14 new features, bugs and security fixes OS-netbsd tests Tests in the Lib/test dir type-bug An unexpected behavior, bug, or error

Comments

@furkanonder
Copy link
Contributor

furkanonder commented Sep 15, 2024

Bug report

Bug description:

localhost$ ./python -m test test_locale -m test_strcoll_with_diacritic -m test_strxfrm_with_diacritic -v
== CPython 3.14.0a0 (heads/main:401fff7423c, Sep 15 2024, 21:20:00) [GCC 10.5.0]
== NetBSD-10.0-amd64-x86_64-64bit-ELF little-endian
== Python build: debug
== cwd: /home/blue/cpython/build/test_python_worker_28241æ
== CPU count: 6
== encodings: locale=UTF-8 FS=utf-8
== resources: all test resources are disabled, use -u option to unskip tests

Using random seed: 1742921980
0:00:00 load avg: 0.18 Run 1 test sequentially in a single process
0:00:00 load avg: 0.18 [1/1] test_locale
test_strcoll_with_diacritic (test.test_locale.TestEnUSCollation.test_strcoll_with_diacritic) ... testing with 'en_US.UTF-8'... FAIL
test_strxfrm_with_diacritic (test.test_locale.TestEnUSCollation.test_strxfrm_with_diacritic) ... testing with 'en_US.UTF-8'... FAIL

======================================================================
FAIL: test_strcoll_with_diacritic (test.test_locale.TestEnUSCollation.test_strcoll_with_diacritic)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/blue/cpython/Lib/test/test_locale.py", line 359, in test_strcoll_with_diacritic
    self.assertLess(locale.strcoll('à', 'b'), 0)
    ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: 126 not less than 0

======================================================================
FAIL: test_strxfrm_with_diacritic (test.test_locale.TestEnUSCollation.test_strxfrm_with_diacritic)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/blue/cpython/Lib/test/test_locale.py", line 368, in test_strxfrm_with_diacritic
    self.assertLess(locale.strxfrm('à'), locale.strxfrm('b'))
    ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: 'à' not less than 'b'

----------------------------------------------------------------------
Ran 2 tests in 0.013s

FAILED (failures=2)
test test_locale failed
test_locale failed (2 failures)

== Tests result: FAILURE ==

1 test failed:
    test_locale

Total duration: 266 ms
Total tests: run=2 (filtered) failures=2
Total test files: run=1/1 (filtered) failed=1
Result: FAILURE
localhost$

OS: NetBSD 10.0 amd64

CPython versions tested on:

CPython main branch

Operating systems tested on:

Other

Linked PRs

@furkanonder furkanonder added type-bug An unexpected behavior, bug, or error tests Tests in the Lib/test dir 3.12 only security fixes 3.13 bugs and security fixes 3.14 new features, bugs and security fixes labels Sep 15, 2024
@furkanonder
Copy link
Contributor Author

NetBSD doesn't support UTF-8 for LC_COLLATE. See https://www.unitedbsd.com/d/1437-issues-running-cpython-locale-tests-on-netbsd-100/2

@vstinner vstinner changed the title test_strcoll_with_diacritic and test_strxfrm_with_diacritic tests failing on NetBSD test_locale: test_strcoll_with_diacritic and test_strxfrm_with_diacritic tests failing on NetBSD Sep 16, 2024
vstinner pushed a commit that referenced this issue Sep 16, 2024
…124110)

Skip test_strcoll_with_diacritic() and test_strxfrm_with_diacritic()
of test_locale on NetBSD due to lack of UTF-8 LC_COLLATE
support.
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Sep 16, 2024
…tBSD (pythonGH-124110)

Skip test_strcoll_with_diacritic() and test_strxfrm_with_diacritic()
of test_locale on NetBSD due to lack of UTF-8 LC_COLLATE
support.
(cherry picked from commit 10de360)

Co-authored-by: Furkan Onder <[email protected]>
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Sep 16, 2024
…tBSD (pythonGH-124110)

Skip test_strcoll_with_diacritic() and test_strxfrm_with_diacritic()
of test_locale on NetBSD due to lack of UTF-8 LC_COLLATE
support.
(cherry picked from commit 10de360)

Co-authored-by: Furkan Onder <[email protected]>
vstinner pushed a commit that referenced this issue Sep 16, 2024
…etBSD (GH-124110) (#124147)

GH-124108: Skip test_locale.test_strcoll_with_diacritic() on NetBSD (GH-124110)

Skip test_strcoll_with_diacritic() and test_strxfrm_with_diacritic()
of test_locale on NetBSD due to lack of UTF-8 LC_COLLATE
support.
(cherry picked from commit 10de360)

Co-authored-by: Furkan Onder <[email protected]>
savannahostrowski pushed a commit to savannahostrowski/cpython that referenced this issue Sep 22, 2024
…tBSD (python#124110)

Skip test_strcoll_with_diacritic() and test_strxfrm_with_diacritic()
of test_locale on NetBSD due to lack of UTF-8 LC_COLLATE
support.
Yhg1s pushed a commit that referenced this issue Sep 23, 2024
…etBSD (GH-124110) (#124146)

GH-124108: Skip test_locale.test_strcoll_with_diacritic() on NetBSD (GH-124110)

Skip test_strcoll_with_diacritic() and test_strxfrm_with_diacritic()
of test_locale on NetBSD due to lack of UTF-8 LC_COLLATE
support.
(cherry picked from commit 10de360)

Co-authored-by: Furkan Onder <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3.12 only security fixes 3.13 bugs and security fixes 3.14 new features, bugs and security fixes OS-netbsd tests Tests in the Lib/test dir type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

No branches or pull requests

2 participants