Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 906697 - dev-python/click-8.1.3 fails tests (MUSL-SYSTEM)
Summary: dev-python/click-8.1.3 fails tests (MUSL-SYSTEM)
Status: CONFIRMED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Python Gentoo Team
URL:
Whiteboard:
Keywords: TESTFAILURE
Depends on:
Blocks:
 
Reported: 2023-05-18 17:34 UTC by Agostino Sarubbo
Modified: 2023-06-30 08:57 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build.log (build.log,116.92 KB, text/plain)
2023-05-18 17:34 UTC, Agostino Sarubbo
Details
click-8.1.3:20230630-063739.log.gz (click-8.1.3:20230630-063739.log.gz,26.86 KB, application/gzip)
2023-06-30 08:50 UTC, Paolo Pedroni
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2023-05-18 17:34:20 UTC
https://blogs.gentoo.org/ago/2020/07/04/gentoo-tinderbox/

Issue: dev-python/click-8.1.3 fails tests (MUSL-SYSTEM).
Discovered on: amd64 (internal ref: tinderbox_musl)

NOTE:
(MUSL-SYSTEM) in the summary means that bug was found on a machine that runs MUSL libc but this bug MAY or MAY NOT BE related to musl.
Comment 1 Agostino Sarubbo gentoo-dev 2023-05-18 17:34:22 UTC
Created attachment 861912 [details]
build.log

build log and emerge --info
Comment 2 Agostino Sarubbo gentoo-dev 2023-05-18 17:34:23 UTC
Error(s) that match a know pattern:


E               AttributeError: can't set attribute 'encoding'
E       AttributeError: can't set attribute 'encoding'
ERROR tests/test_arguments.py::test_bytes_args - AttributeError: can't set at...
FAILED tests/test_arguments.py::test_bytes_args - AttributeError: can't set a...
tests/test_basic.py::test_float_option[--f=x-Error: Invalid value for '--f': 'x' is not a valid float.] PASSED [ 55/598]
tests/test_basic.py::test_int_option[args2-Error: Invalid value for '--i': 'x' is not a valid integer.] PASSED [ 49/598]
tests/test_basic.py::test_string_option[args2-Error: Option '--s' requires an argument.] PASSED [ 44/598]
tests/test_basic.py::test_uuid_option[args2-Error: Invalid value for '--u': 'x' is not a valid UUID.] PASSED [ 52/598]
tests/test_commands.py::test_group_with_args[args0-2-Error: Missing command.] PASSED [118/598]
Comment 3 Paolo Pedroni 2023-06-30 08:48:38 UTC
With glibc-2.37-r3 and python-3.11.4 it fails the same test, in the same place, but with a different error. Shall I open a new bug or can I follow up here?

=================================================================================================================== FAILURES ===================================================================================================================
_______________________________________________________________________________________________________________ test_bytes_args ________________________________________________________________________________________________________________

runner = <click.testing.CliRunner object at 0x7f8d90659710>, monkeypatch = <_pytest.monkeypatch.MonkeyPatch object at 0x7f8d9065a110>

    def test_bytes_args(runner, monkeypatch):
        @click.command()
        @click.argument("arg")
        def from_bytes(arg):
            assert isinstance(
                arg, str
            ), "UTF-8 encoded argument should be implicitly converted to Unicode"
    
        # Simulate empty locale environment variables
>       monkeypatch.setattr(sys.stdin, "encoding", "utf-8")
E       AttributeError: property 'encoding' of 'DontReadFromInput' object has no setter

from_bytes = <Command from-bytes>
monkeypatch = <_pytest.monkeypatch.MonkeyPatch object at 0x7f8d9065a110>
runner     = <click.testing.CliRunner object at 0x7f8d90659710>

tests/test_arguments.py:89: AttributeError
=========================================================================================================== short test summary info ============================================================================================================
SKIPPED [16] tests/test_termui.py:328: Tests user-input using the msvcrt module.
SKIPPED [3] tests/test_termui.py:338: Tests special character inputs using the msvcrt module.
SKIPPED [2] tests/test_termui.py:353: Tests user-input using the msvcrt module.
XFAIL tests/test_chain.py::test_multicommand_chaining
ERROR tests/test_arguments.py::test_bytes_args - AttributeError: property 'encoding' of 'DontReadFromInput' object has no setter
FAILED tests/test_arguments.py::test_bytes_args - AttributeError: property 'encoding' of 'DontReadFromInput' object has no setter
======================================================================================== 1 failed, 575 passed, 21 skipped, 1 xfailed, 1 error in 1.55s =========================================================================================
Comment 4 Paolo Pedroni 2023-06-30 08:50:01 UTC
Created attachment 864864 [details]
click-8.1.3:20230630-063739.log.gz
Comment 5 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-06-30 08:57:50 UTC
Same bug is okay here because it looks similar enough (+ recent enough time, it's not a bug from ages ago). Thanks for checking!