#1140875 python-docx: autopkgtest regression with pytest 9.1

#1140875#5
Date:
2026-06-27 21:23:24 UTC
From:
To:
Dear maintainer,

According to https://ci.debian.net data, your package python-docx has an
autopkgtest regression with pytest.

The following architectures failed: amd64, arm64, i386, loong64,
ppc64el, riscv64, s390x.

Hopefully relevant excerpt from
https://ci.debian.net/packages/p/python-docx/testing/amd64/72542157/
follows:

101s ==================================== ERRORS ====================================
101s _ ERROR at setup of DescribeDirPkgReader.it_doesnt_mind_being_closed_even_though_it_doesnt_need_it _
101s E                   pytest.PytestRemovedIn10Warning: Class-scoped fixture defined as instance method is deprecated.
101s E                   Instance attributes set in this fixture will NOT be visible to test methods,
101s E                   as each test gets a new instance while the fixture runs only once per class.
101s E                   Use @classmethod decorator and set attributes on cls instead.
101s E                   See https://docs.pytest.org/en/stable/deprecations.html#class-scoped-fixture-as-instance-method
101s _ ERROR at setup of DescribeDirPkgReader.it_can_retrieve_the_blob_for_a_pack_uri _
101s E       AssertionError
101s ___ ERROR at setup of DescribeDirPkgReader.it_can_get_the_content_types_xml ____
101s E       AssertionError
101s _ ERROR at setup of DescribeDirPkgReader.it_can_retrieve_the_rels_xml_for_a_source_uri _
101s E       AssertionError
101s _ ERROR at setup of DescribeDirPkgReader.it_returns_none_when_part_has_no_rels_xml _
101s E       AssertionError
101s _ ERROR at setup of DescribeZipPkgReader.it_can_retrieve_the_blob_for_a_pack_uri _
101s E                   pytest.PytestRemovedIn10Warning: Class-scoped fixture defined as instance method is deprecated.
101s E                   Instance attributes set in this fixture will NOT be visible to test methods,
101s E                   as each test gets a new instance while the fixture runs only once per class.
101s E                   Use @classmethod decorator and set attributes on cls instead.
101s E                   See https://docs.pytest.org/en/stable/deprecations.html#class-scoped-fixture-as-instance-method
101s _____ ERROR at setup of DescribeZipPkgReader.it_has_the_content_types_xml ______
101s E       AssertionError
101s _ ERROR at setup of DescribeZipPkgReader.it_can_retrieve_rels_xml_for_source_uri _
101s E       AssertionError
101s _ ERROR at setup of DescribeZipPkgReader.it_returns_none_when_part_has_no_rels_xml _
101s E       AssertionError
101s ERROR tests/opc/test_phys_pkg.py::DescribeDirPkgReader::it_doesnt_mind_being_closed_even_though_it_doesnt_need_it
101s ERROR tests/opc/test_phys_pkg.py::DescribeDirPkgReader::it_can_retrieve_the_blob_for_a_pack_uri
101s ERROR tests/opc/test_phys_pkg.py::DescribeDirPkgReader::it_can_get_the_content_types_xml
101s ERROR tests/opc/test_phys_pkg.py::DescribeDirPkgReader::it_can_retrieve_the_rels_xml_for_a_source_uri
101s ERROR tests/opc/test_phys_pkg.py::DescribeDirPkgReader::it_returns_none_when_part_has_no_rels_xml
101s ERROR tests/opc/test_phys_pkg.py::DescribeZipPkgReader::it_can_retrieve_the_blob_for_a_pack_uri
101s ERROR tests/opc/test_phys_pkg.py::DescribeZipPkgReader::it_has_the_content_types_xml
101s ERROR tests/opc/test_phys_pkg.py::DescribeZipPkgReader::it_can_retrieve_rels_xml_for_source_uri
101s ERROR tests/opc/test_phys_pkg.py::DescribeZipPkgReader::it_returns_none_when_part_has_no_rels_xml
101s E: pybuild pybuild:485: test: plugin pyproject failed with: exit code=1: cd /tmp/autopkgtest-lxc.e3zl9hid/downtmp/autopkgtest_tmp/build; python3.14 -m pytest tests
109s ==================================== ERRORS ====================================
109s _ ERROR at setup of DescribeDirPkgReader.it_doesnt_mind_being_closed_even_though_it_doesnt_need_it _
109s E                   pytest.PytestRemovedIn10Warning: Class-scoped fixture defined as instance method is deprecated.
109s E                   Instance attributes set in this fixture will NOT be visible to test methods,
109s E                   as each test gets a new instance while the fixture runs only once per class.
109s E                   Use @classmethod decorator and set attributes on cls instead.
109s E                   See https://docs.pytest.org/en/stable/deprecations.html#class-scoped-fixture-as-instance-method
109s _ ERROR at setup of DescribeDirPkgReader.it_can_retrieve_the_blob_for_a_pack_uri _
109s E       AssertionError
109s ___ ERROR at setup of DescribeDirPkgReader.it_can_get_the_content_types_xml ____
109s E       AssertionError
109s _ ERROR at setup of DescribeDirPkgReader.it_can_retrieve_the_rels_xml_for_a_source_uri _
109s E       AssertionError
109s _ ERROR at setup of DescribeDirPkgReader.it_returns_none_when_part_has_no_rels_xml _
109s E       AssertionError
109s _ ERROR at setup of DescribeZipPkgReader.it_can_retrieve_the_blob_for_a_pack_uri _
109s E                   pytest.PytestRemovedIn10Warning: Class-scoped fixture defined as instance method is deprecated.
109s E                   Instance attributes set in this fixture will NOT be visible to test methods,
109s E                   as each test gets a new instance while the fixture runs only once per class.
109s E                   Use @classmethod decorator and set attributes on cls instead.
109s E                   See https://docs.pytest.org/en/stable/deprecations.html#class-scoped-fixture-as-instance-method
109s _____ ERROR at setup of DescribeZipPkgReader.it_has_the_content_types_xml ______
109s E       AssertionError
109s _ ERROR at setup of DescribeZipPkgReader.it_can_retrieve_rels_xml_for_source_uri _
109s E       AssertionError
109s _ ERROR at setup of DescribeZipPkgReader.it_returns_none_when_part_has_no_rels_xml _
109s E       AssertionError
109s ERROR tests/opc/test_phys_pkg.py::DescribeDirPkgReader::it_doesnt_mind_being_closed_even_though_it_doesnt_need_it
109s ERROR tests/opc/test_phys_pkg.py::DescribeDirPkgReader::it_can_retrieve_the_blob_for_a_pack_uri
109s ERROR tests/opc/test_phys_pkg.py::DescribeDirPkgReader::it_can_get_the_content_types_xml
109s ERROR tests/opc/test_phys_pkg.py::DescribeDirPkgReader::it_can_retrieve_the_rels_xml_for_a_source_uri
109s ERROR tests/opc/test_phys_pkg.py::DescribeDirPkgReader::it_returns_none_when_part_has_no_rels_xml
109s ERROR tests/opc/test_phys_pkg.py::DescribeZipPkgReader::it_can_retrieve_the_blob_for_a_pack_uri
109s ERROR tests/opc/test_phys_pkg.py::DescribeZipPkgReader::it_has_the_content_types_xml
109s ERROR tests/opc/test_phys_pkg.py::DescribeZipPkgReader::it_can_retrieve_rels_xml_for_source_uri
109s ERROR tests/opc/test_phys_pkg.py::DescribeZipPkgReader::it_returns_none_when_part_has_no_rels_xml
109s E: pybuild pybuild:485: test: plugin pyproject failed with: exit code=1: cd /tmp/autopkgtest-lxc.e3zl9hid/downtmp/autopkgtest_tmp/build; python3.13 -m pytest tests
109s pybuild-autopkgtest: error: pybuild --autopkgtest --test-pytest -i python{version} -p "3.14 3.13" --parallel= returned exit code 13
109s pybuild-autopkgtest: error: /tmp/Lj2rqsbL8X/run pybuild-autopkgtest returned exit code 2
109s pybuild-autopkgtest  FAIL non-zero exit status 25
110s pybuild-autopkgtest  FAIL non-zero exit status 25

#1140875#12
Date:
2026-06-28 22:55:18 UTC
From:
To:
Hello,

Bug #1140875 in python-docx reported by you has been fixed in the
Git repository and is awaiting an upload. You can see the commit
message below and you can check the diff of the fix at:

https://salsa.debian.org/python-team/packages/python-docx/-/commit/ee0e1983bef4079957299000facd5d7b3b7aecc9
------------------------------------------------------------------------
Don't define class-scoped fixtures as instance methods

Closes: #1140875
------------------------------------------------------------------------

(this message was generated automatically)
-- 
Greetings

https://bugs.debian.org/1140875

#1140875#19
Date:
2026-06-28 23:46:25 UTC
From:
To:
We believe that the bug you reported is fixed in the latest version of
python-docx, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 1140875@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Colin Watson <cjwatson@debian.org> (supplier of updated python-docx package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
Format: 1.8
Date: Sun, 28 Jun 2026 23:54:24 +0100
Source: python-docx
Architecture: source
Version: 1.2.0+dfsg-4
Distribution: unstable
Urgency: medium
Maintainer: Debian Python Team <team+python@tracker.debian.org>
Changed-By: Colin Watson <cjwatson@debian.org>
Closes: 1140875
Changes:
 python-docx (1.2.0+dfsg-4) unstable; urgency=medium
 .
   * Team upload.
   * Don't define class-scoped fixtures as instance methods (closes:
     #1140875).
   * Standards-Version: 4.7.4.
Checksums-Sha1:
 ecb6ea7b60bd21eb18c49ec52888f54eb1fbf2b8 2537 python-docx_1.2.0+dfsg-4.dsc
 c6aea04dae5de633b9a113f7c2c5e15c2c44065e 8648 python-docx_1.2.0+dfsg-4.debian.tar.xz
 6c601594590bf9bf544fef2b1ac340dba4f59884 2232192 python-docx_1.2.0+dfsg-4.git.tar.xz
 8606e02fdbfefe4af8d44f71d54400e194ad028b 17532 python-docx_1.2.0+dfsg-4_source.buildinfo
Checksums-Sha256:
 659c6630a33258c6b05beaad8e4b8d3b408b6ccefedc01360c55310efc450e91 2537 python-docx_1.2.0+dfsg-4.dsc
 b6e9cb531c6eed6b712de647d39c9a1998716813ad386f4dc9e82a3a5f54392f 8648 python-docx_1.2.0+dfsg-4.debian.tar.xz
 02a0912245e425a3795e3fa2b89f0cf60334807b98f7483f5a6126136cfec7bc 2232192 python-docx_1.2.0+dfsg-4.git.tar.xz
 ecf39d032e78535ea7036c50a3e05a2c9451522dcf7e91c657d104862fb7cc70 17532 python-docx_1.2.0+dfsg-4_source.buildinfo
Files:
 0d0e486bc5576d91fa3d4be9a7506fed 2537 python optional python-docx_1.2.0+dfsg-4.dsc
 67170c9fcd9b35c9687e9cc5ede81aa1 8648 python optional python-docx_1.2.0+dfsg-4.debian.tar.xz
 b196efba5ff9ad9e8925943e5955bc5c 2232192 python None python-docx_1.2.0+dfsg-4.git.tar.xz
 a1914a399bc7c340923d91dd5cec03ab 17532 python optional python-docx_1.2.0+dfsg-4_source.buildinfo
Git-Tag-Info: tag=f6236f591a79e6e5e6368cbc3c0c541e061c1358 fp=ac0a4ff12611b6fccf01c111393587d97d86500b
Git-Tag-Tagger: Colin Watson <cjwatson@debian.org>
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEN02M5NuW6cvUwJcqYG0ITkaDwHkFAmpBpr4ACgkQYG0ITkaD
wHkDnA/+NNZlUbogtLxrhDOnNEN4klRnTby9uZ3i4Y6RmCIWaAcEQk4sYmmhloP2
oCcaQ5LmvDq1c2fUKhdKLFOKzvRGIRUpPHNSoumVHDtpqQ3faJYFeNZzV5ql3IEk
XA150Bkn0RJTeAJo63/wSHEet6ilgbgwbz0jhDWQgWNwfjTf2rwFZ21BR7HG2gRz
e7KT78YliZucjxXxQ7iPQuuNiF5A32qQv5dhzlzjMZ6sznrar0FJZIXNbvDNuHpl
Vhtb3WMOH9j0MKHUOATxZRHZoBxSggRPUUT+B4rK/fDhalgeZhfRm0KhQQ+eM9se
8fjKzkAvGQ+ws1Ws3KpuTx/r/FH4+HmOeFhufDNdXCopMfSJhI0AYfalPALz9k0i
0PzQRRAvgkuIcr5Rf6gTnxlW8fhFFg+jdOSo6U6p26I5Jlua2YBeiY+e2hrLVFJ/
4pPw/WPafsPPhVFW4pqERaDDocBjlAXwmpXjXMrVf30wHUQCHvc1Jxrn5vdqS/Ib
Rp004dmIO7aj4t5dUM2jYgA27W+xZCZnHO0pQRGNCTaKo4sC1yOWy5onVhtVE5oO
ZAStC9yRasNaWvkuG1vSNLhQS/hps1+y1D2UHw08kiqLBNAtDKiT1fPSNrfNvDDk
nlXmhFADEQ9/mrlFBHmGt2qauoGdNr+i2ATn43k3FnsZ4QoqRwo=
=LjUt
-----END PGP SIGNATURE-----