Bug#945993: diffoscope: FAILED tests/test_source.py::test_code_is_black_clean - assert 228381 == 0

Chris Lamb lamby at debian.org
Mon Dec 2 19:37:02 GMT 2019


Hi Julien,

> It seems to me the test is inherently extremely sensitive to the exact
> version of black used, so it probably shouldn't be part of autopkgtests?

Mmm, except I anticipated this at the time with the following
commit:

  https://salsa.debian.org/reproducible-builds/diffoscope/commit/aefa5a39bb5f86f21cb67f94a013aa2c9bc4b69d

At a quick guess, I think this is problem caused by the autopkgtests
being run without the pyproject.toml. As in:

--- a/debian/tests/pytest
+++ b/debian/tests/pytest
@@ -14,7 +14,7 @@ fi

 for py in $(py3versions -s); do
     echo "@@@@@@@@ Running against $py"
-    cp -r tests "$AUTOPKGTEST_TMP"
+    cp -r tests pyproject.toml "$AUTOPKGTEST_TMP"
     (cd "$AUTOPKGTEST_TMP"; "$py" -m pytest -vv -l -r a)
     rm -rf "${AUTOPKGTEST_TMP:?}"/*
 done

… will likely fix this.


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      lamby at debian.org 🍥 chris-lamb.co.uk
       `-



More information about the Reproducible-builds mailing list