Source: pyls-black
Version: 0.4.6-3
Severity: serious
Justification: FTBFS
Tags: bookworm sid ftbfs
User: lu...@debian.org
Usertags: ftbfs-20211023 ftbfs-bookworm

Hi,

During a rebuild of all packages in sid, your package failed to build
on amd64.


Relevant part (hopefully):
> dpkg-buildpackage
> -----------------
> 
> Command: dpkg-buildpackage -us -uc -sa -rfakeroot
> dpkg-buildpackage: info: source package pyls-black
> dpkg-buildpackage: info: source version 0.4.6-3
> dpkg-buildpackage: info: source distribution unstable
> dpkg-buildpackage: info: source changed by Julian Gilbey <j...@debian.org>
>  dpkg-source --before-build .
> dpkg-buildpackage: info: host architecture amd64
>  debian/rules clean
> dh clean --buildsystem=pybuild
>    dh_auto_clean -O--buildsystem=pybuild
> I: pybuild base:232: python3.9 setup.py clean 
> running clean
> removing '/<<PKGBUILDDIR>>/.pybuild/cpython3_3.9/build' (and everything under 
> it)
> 'build/bdist.linux-x86_64' does not exist -- can't clean it
> 'build/scripts-3.9' does not exist -- can't clean it
>    dh_autoreconf_clean -O--buildsystem=pybuild
>    dh_clean -O--buildsystem=pybuild
>  dpkg-source -b .
> dpkg-source: info: using source format '3.0 (quilt)'
> dpkg-source: info: building pyls-black using existing 
> ./pyls-black_0.4.6.orig.tar.gz
> dpkg-source: info: using patch list from debian/patches/series
> dpkg-source: info: building pyls-black in pyls-black_0.4.6-3.debian.tar.xz
> dpkg-source: info: building pyls-black in pyls-black_0.4.6-3.dsc
>  debian/rules binary
> dh binary --buildsystem=pybuild
>    dh_update_autotools_config -O--buildsystem=pybuild
>    dh_autoreconf -O--buildsystem=pybuild
>    dh_auto_configure -O--buildsystem=pybuild
> I: pybuild base:232: python3.9 setup.py config 
> running config
>    dh_auto_build -O--buildsystem=pybuild
> I: pybuild base:232: /usr/bin/python3 setup.py build 
> running build
> running build_py
> creating /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9/build/pyls_black
> copying pyls_black/__init__.py -> 
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9/build/pyls_black
> copying pyls_black/plugin.py -> 
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9/build/pyls_black
>    dh_auto_test -O--buildsystem=pybuild
> I: pybuild base:232: cd /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9/build; 
> python3.9 -m pytest tests
> ============================= test session starts 
> ==============================
> platform linux -- Python 3.9.7, pytest-6.2.5, py-1.10.0, pluggy-0.13.0
> rootdir: /<<PKGBUILDDIR>>
> collected 16 items
> 
> tests/test_plugin.py .............F.s                                    
> [100%]
> 
> =================================== FAILURES 
> ===================================
> ____________________________ test_load_config_py36 
> _____________________________
> 
>     def test_load_config_py36():
> >       config = load_config(str(fixtures_dir / "py36" / "example.py"))
> 
> tests/test_plugin.py:193: 
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
> _ 
> 
> filename = 
> '/<<PKGBUILDDIR>>/.pybuild/cpython3_3.9/build/tests/fixtures/py36/example.py'
> 
>     def load_config(filename: str) -> Dict:
>         defaults = {
>             "line_length": 88,
>             "fast": False,
>             "pyi": filename.endswith(".pyi"),
>             "skip_string_normalization": False,
>             "target_version": set(),
>         }
>     
>         root = black.find_project_root((filename,))
>     
>         pyproject_filename = root / "pyproject.toml"
>     
>         if not pyproject_filename.is_file():
>             return defaults
>     
>         try:
>             pyproject_toml = toml.load(str(pyproject_filename))
>         except (toml.TomlDecodeError, OSError):
>             return defaults
>     
>         file_config = pyproject_toml.get("tool", {}).get("black", {})
>         file_config = {
>             key.replace("--", "").replace("-", "_"): value
>             for key, value in file_config.items()
>         }
>     
>         config = {
>             key: file_config.get(key, default_value)
>             for key, default_value in defaults.items()
>         }
>     
>         if file_config.get("target_version"):
>             target_version = set(
>                 black.TargetVersion[x.upper()] for x in 
> file_config["target_version"]
>             )
>         elif file_config.get("py36"):
> >           target_version = black.PY36_VERSIONS
> E           AttributeError: module 'black' has no attribute 'PY36_VERSIONS'
> 
> pyls_black/plugin.py:100: AttributeError
> =========================== short test summary info 
> ============================
> FAILED tests/test_plugin.py::test_load_config_py36 - AttributeError: module 
> '...
> =================== 1 failed, 14 passed, 1 skipped in 0.25s 
> ====================
> E: pybuild pybuild:354: test: plugin distutils failed with: exit code=1: cd 
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.9/build; python3.9 -m pytest tests
> dh_auto_test: error: pybuild --test --test-pytest -i python{version} -p 3.9 
> returned exit code 13


The full build log is available from:
http://qa-logs.debian.net/2021/10/23/pyls-black_0.4.6-3_unstable.log

A list of current common problems and possible solutions is available at
http://wiki.debian.org/qa.debian.org/FTBFS . You're welcome to contribute!

If you reassign this bug to another package, please marking it as 'affects'-ing
this package. See https://www.debian.org/Bugs/server-control#affects

If you fail to reproduce this, please provide a build log and diff it with mine
so that we can identify if something relevant changed in the meantime.

Reply via email to