Package: src:poetry-plugin-export
Version: 1.9.0-2
Severity: serious
Tags: ftbfs forky sid

Dear maintainer:

During a rebuild of all packages in unstable, this package failed to build.

Below you will find the last part of the build log (probably the most
relevant part, but not necessarily). If required, the full build log
is available here:

https://people.debian.org/~sanvila/build-logs/202510/

About the archive rebuild: The build was made on virtual machines from AWS,
using sbuild and a reduced chroot with only build-essential packages.

If you cannot reproduce the bug please contact me privately, as I
am willing to provide ssh access to a virtual machine where the bug is
fully reproducible.

If this is really a bug in one of the build-depends, please use
reassign and add an affects on src:poetry-plugin-export, so that this is still
visible in the BTS web page for this package.

Thanks.

--------------------------------------------------------------------------------
[...]
 debian/rules clean
dh clean --with python3 --buildsystem=pybuild
   debian/rules override_dh_auto_clean
make[1]: Entering directory '/<<PKGBUILDDIR>>'
find . -iname '*.pyc' -delete
for i in $(find . -type d -iname __pycache__) ; do rm -rf $i ; done
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
   dh_autoreconf_clean -O--buildsystem=pybuild
   dh_clean -O--buildsystem=pybuild
 debian/rules binary
dh binary --with python3 --buildsystem=pybuild
   dh_update_autotools_config -O--buildsystem=pybuild
   dh_autoreconf -O--buildsystem=pybuild
   dh_auto_configure -O--buildsystem=pybuild
   dh_auto_build -O--buildsystem=pybuild
I: pybuild plugin_pyproject:129: Building wheel for python3.13 with "build" 
module
I: pybuild base:311: python3.13 -m build --skip-dependency-check --no-isolation 
--wheel --outdir /<<PKGBUILDDIR>>/.pybuild/cpython3_3.13_poetry-plugin-export  
* Building wheel...
Successfully built poetry_plugin_export-1.9.0-py3-none-any.whl
I: pybuild plugin_pyproject:144: Unpacking wheel built for python3.13 with 
"installer" module
   dh_auto_test -O--buildsystem=pybuild
I: pybuild base:311: cd 
/<<PKGBUILDDIR>>/.pybuild/cpython3_3.13_poetry-plugin-export/build; python3.13 
-m pytest tests
============================= test session starts ==============================
platform linux -- Python 3.13.7, pytest-8.4.2, pluggy-1.6.0
rootdir: /<<PKGBUILDDIR>>/.pybuild/cpython3_3.13_poetry-plugin-export/build
configfile: pyproject.toml
plugins: xdist-3.8.0, cov-5.0.0, mock-3.15.0
created: 2/2 workers
2 workers [141 items]

...................................F.................................... [ 51%]
.........................F...........................................    [100%]
=================================== FAILURES ===================================
_ test_exporter_exports_requirements_txt_without_dev_packages_by_default[1.1] __
[gw0] linux -- Python 3.13.7 /usr/bin/python3.13

tmp_path = 
PosixPath('/tmp/pytest-of-sbuild/pytest-0/popen-gw0/test_exporter_exports_requirem0')
poetry = <poetry.poetry.Poetry object at 0x7f6be4e7f070>, lock_version = '1.1'

    @pytest.mark.parametrize("lock_version", ("1.1", "2.1"))
    def test_exporter_exports_requirements_txt_without_dev_packages_by_default(
        tmp_path: Path, poetry: Poetry, lock_version: str
    ) -> None:
        lock_data: dict[str, Any] = {
            "package": [
                {
                    "name": "foo",
                    "version": "1.2.3",
                    "optional": False,
                    "python-versions": "*",
                },
                {
                    "name": "bar",
                    "version": "4.5.6",
                    "optional": False,
                    "python-versions": "*",
                },
            ],
            "metadata": {
                "lock-version": lock_version,
                "python-versions": "*",
                "content-hash": "123456789",
                "files": {
                    "foo": [{"name": "foo.whl", "hash": "12345"}],
                    "bar": [{"name": "bar.whl", "hash": "67890"}],
                },
            },
        }
        fix_lock_data(lock_data)
        if lock_version == "2.1":
            lock_data["package"][1]["groups"] = ["dev"]
        poetry.locker.mock_lock_data(lock_data)  # type: ignore[attr-defined]
        set_package_requires(poetry, dev={"bar"})
    
        exporter = Exporter(poetry, NullIO())
        exporter.export("requirements.txt", tmp_path, "requirements.txt")
    
        with (tmp_path / "requirements.txt").open(encoding="utf-8") as f:
            content = f.read()
    
        expected = f"""\
    foo==1.2.3 ; {MARKER_PY} \\
        --hash=sha256:12345
    """
    
>       assert content == expected
E       assert 'bar==4.5.6 ;...ha256:12345\n' == 'foo==1.2.3 ;...ha256:12345\n'
E         
E         + bar==4.5.6 ; python_version == "2.7" or python_version >= "3.6" and 
python_version < "4.0" \
E         +     --hash=sha256:67890
E           foo==1.2.3 ; python_version == "2.7" or python_version >= "3.6" and 
python_version < "4.0" \
E               --hash=sha256:12345

tests/test_exporter.py:797: AssertionError
------------------------------ Captured log setup ------------------------------
WARNING  poetry.core.factory:factory.py:64 The "poetry.dev-dependencies" 
section is deprecated and will be removed in a future version. Use 
"poetry.group.dev.dependencies" instead.
_ test_exporter_exports_requirements_txt_with_dev_extras[1.1-False-expected1] __
[gw1] linux -- Python 3.13.7 /usr/bin/python3.13

tmp_path = 
PosixPath('/tmp/pytest-of-sbuild/pytest-0/popen-gw1/test_exporter_exports_requirem7')
poetry = <poetry.poetry.Poetry object at 0x7fa553bfbcf0>, dev = False
expected = ['bar==1.2.2 ; python_version == "2.7" or python_version >= "3.6" 
and python_version < "4.0"', 'foo==1.2.1 ; python_version == "2.7" or 
python_version >= "3.6" and python_version < "4.0"']
lock_version = '1.1'

    @pytest.mark.parametrize(
        ["dev", "expected"],
        [
            (
                True,
                [
                    f"bar==1.2.2 ; {MARKER_PY}",
                    f"baz==1.2.3 ; {MARKER_PY}",
                    f"foo==1.2.1 ; {MARKER_PY}",
                ],
            ),
            (
                False,
                [
                    f"bar==1.2.2 ; {MARKER_PY}",
                    f"foo==1.2.1 ; {MARKER_PY}",
                ],
            ),
        ],
    )
    @pytest.mark.parametrize("lock_version", ("1.1", "2.1"))
    def test_exporter_exports_requirements_txt_with_dev_extras(
        tmp_path: Path, poetry: Poetry, dev: bool, expected: list[str], 
lock_version: str
    ) -> None:
        lock_data: dict[str, Any] = {
            "package": [
                {
                    "name": "foo",
                    "version": "1.2.1",
                    "optional": False,
                    "python-versions": "*",
                },
                {
                    "name": "bar",
                    "version": "1.2.2",
                    "optional": False,
                    "python-versions": "*",
                    "dependencies": {
                        "baz": {
                            "version": ">=0.1.0",
                            "optional": True,
                            "markers": "extra == 'baz'",
                        }
                    },
                    "extras": {"baz": ["baz (>=0.1.0)"]},
                },
                {
                    "name": "baz",
                    "version": "1.2.3",
                    "optional": False,
                    "python-versions": "*",
                },
            ],
            "metadata": {
                "lock-version": lock_version,
                "python-versions": "*",
                "content-hash": "123456789",
                "files": {"foo": [], "bar": [], "baz": []},
            },
        }
        fix_lock_data(lock_data)
        if lock_version == "2.1":
            lock_data["package"][2]["groups"] = ["dev"]
        poetry.locker.mock_lock_data(lock_data)  # type: ignore[attr-defined]
        set_package_requires(poetry, dev={"baz"})
    
        exporter = Exporter(poetry, NullIO())
        if dev:
            exporter.only_groups([MAIN_GROUP, "dev"])
        exporter.export("requirements.txt", tmp_path, "requirements.txt")
    
        with (tmp_path / "requirements.txt").open(encoding="utf-8") as f:
            content = f.read()
    
>       assert content == "\n".join(expected) + "\n"
E       assert 'bar==1.2.2 ;...ion < "4.0"\n' == 'bar==1.2.2 ;...ion < "4.0"\n'
E         
E         Skipping 81 identical leading characters in diff, use -v to show
E           n < "4.0"
E         + baz==1.2.3 ; python_version == "2.7" or python_version >= "3.6" and 
python_version < "4.0"
E           foo==1.2.1 ; python_version == "2.7" or python_version >= "3.6" and 
python_version < "4.0"

tests/test_exporter.py:1882: AssertionError
------------------------------ Captured log setup ------------------------------
WARNING  poetry.core.factory:factory.py:64 The "poetry.dev-dependencies" 
section is deprecated and will be removed in a future version. Use 
"poetry.group.dev.dependencies" instead.
=========================== short test summary info ============================
FAILED 
tests/test_exporter.py::test_exporter_exports_requirements_txt_without_dev_packages_by_default[1.1]
FAILED 
tests/test_exporter.py::test_exporter_exports_requirements_txt_with_dev_extras[1.1-False-expected1]
======================== 2 failed, 139 passed in 4.55s =========================
E: pybuild pybuild:389: test: plugin pyproject failed with: exit code=1: cd 
/<<PKGBUILDDIR>>/.pybuild/cpython3_3.13_poetry-plugin-export/build; python3.13 
-m pytest tests
dh_auto_test: error: pybuild --test --test-pytest -i python{version} -p 3.13 
returned exit code 13
make: *** [debian/rules:5: binary] Error 25
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2
--------------------------------------------------------------------------------

Reply via email to