Thu Aug 28 19:55:02 UTC 2025 I: starting to build pytest-mypy-testing/forky/arm64 on jenkins on '2025-08-28 19:54' Thu Aug 28 19:55:02 UTC 2025 I: The jenkins build log is/was available at https://jenkins.debian.net/userContent/reproducible/debian/build_service/arm64_11/120318/console.log Thu Aug 28 19:55:02 UTC 2025 I: Downloading source for forky/pytest-mypy-testing=0.1.3-2 --2025-08-28 19:55:02-- http://deb.debian.org/debian/pool/main/p/pytest-mypy-testing/pytest-mypy-testing_0.1.3-2.dsc Connecting to 46.16.76.132:3128... connected. Proxy request sent, awaiting response... 200 OK Length: 2216 (2.2K) [text/prs.lines.tag] Saving to: ‘pytest-mypy-testing_0.1.3-2.dsc’ 0K .. 100% 294M=0s 2025-08-28 19:55:02 (294 MB/s) - ‘pytest-mypy-testing_0.1.3-2.dsc’ saved [2216/2216] Thu Aug 28 19:55:02 UTC 2025 I: pytest-mypy-testing_0.1.3-2.dsc -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Format: 3.0 (quilt) Source: pytest-mypy-testing Binary: python3-pytest-mypy-testing Architecture: all Version: 0.1.3-2 Maintainer: Debian Python Team Uploaders: Julian Gilbey Homepage: https://github.com/davidfritzsche/pytest-mypy-testing Standards-Version: 4.6.2 Vcs-Browser: https://salsa.debian.org/python-team/packages/pytest-mypy-testing Vcs-Git: https://salsa.debian.org/python-team/packages/pytest-mypy-testing.git Testsuite: autopkgtest-pkg-pybuild Build-Depends: debhelper-compat (= 13), dh-sequence-python3, flit, pybuild-plugin-pyproject, python3-all, python3-mypy, python3-pytest Package-List: python3-pytest-mypy-testing deb python optional arch=all Checksums-Sha1: 49084984e9df29b203b3f6be0723ed4c85737d80 28612 pytest-mypy-testing_0.1.3.orig.tar.gz a93888bf14088645a63e63a51605bdc7918b50a4 2192 pytest-mypy-testing_0.1.3-2.debian.tar.xz Checksums-Sha256: 8b7702c0ded93d805ff60af52703de184a1d5a88a039647028bc8897c74283b5 28612 pytest-mypy-testing_0.1.3.orig.tar.gz 1525a3d50f1df3c232f889e6e3442600407143a9d08ad471d40fd67173ebf6b8 2192 pytest-mypy-testing_0.1.3-2.debian.tar.xz Files: adee41d683d063abd9f5a6b9a135a1ef 28612 pytest-mypy-testing_0.1.3.orig.tar.gz 694d0f6bbe1667c3835082ae7cc60aa3 2192 pytest-mypy-testing_0.1.3-2.debian.tar.xz -----BEGIN PGP SIGNATURE----- iQJDBAEBCAAtFiEEfhrD+iemSShMMj72aVxCkxbAe/4FAmY7z+0PHGpkZ0BkZWJp YW4ub3JnAAoJEGlcQpMWwHv+O9gP/2ZSOBc6pehJo11ElPXtFgmbFXTUCauMCnn5 XuwV2qOPFe6WNwagaBAj3nrgk74SDPAsNl06fdjH37i9OEXO0zs6+KDC4D1IJzUP 5GbM4aoQBoNWepeQfI8mgMmzmKUdVMejBYg8S5O5tBLKCUmUJXIxrSjTl23dMvVa WV9+PFvPxkK3rCkv5kHffZ1Wdc66Ro2EXcyF7y0uodMsUJM//nZxct3Pvp4MvXcs LTMPnKveop5ux775yZAKRFODzYnbY8rMx8sDgqxfnhRiZcdbYzCDpE+gnO2oYHQO I+43jLypuRFAKzF5W+NrnPE8wdrxckwjMOZQQeNcDfjKLgRGatV/8jtYhMKpgPv0 8Gy8hBbVSPFsnndP9ntVNOw+bHJul1YnIRe01DDSRbOk21NxRGBNconB19usPRps YA3ac/FIts/v6IJKZviDKB2JA12aoAmFF22pxcI9vq/BnyW855VEhClCrwyC7L7e PYzxSXa4at/Yu4WfBUeRNgWKWhh2lfyLYS+64Y3yQ/3J0kgDNRWr0/xx3ngGEWp8 zyK4jBcoQWn7JJnL65GxYx07oR/pIwyR2rR09dBo4YxeGhPIxiZf3Xv8dXysNJCd R65q7valPnxtWGtGcR29ADmS3FdL94seBksp6+qwdC9yvw4S1zm+rJ5PNhV/nVlq dPnESSa/ =Jl7y -----END PGP SIGNATURE----- Thu Aug 28 19:55:02 UTC 2025 I: Checking whether the package is not for us Thu Aug 28 19:55:02 UTC 2025 I: Starting 1st build on remote node codethink04-arm64.debian.net. Thu Aug 28 19:55:02 UTC 2025 I: Preparing to do remote build '1' on codethink04-arm64.debian.net. Thu Aug 28 20:02:32 UTC 2025 I: Deleting $TMPDIR on codethink04-arm64.debian.net. I: pbuilder: network access will be disabled during build I: Current time: Thu Aug 28 07:55:03 -12 2025 I: pbuilder-time-stamp: 1756410903 I: Building the build Environment I: extracting base tarball [/var/cache/pbuilder/forky-reproducible-base.tgz] I: copying local configuration W: --override-config is not set; not updating apt.conf Read the manpage for details. I: mounting /proc filesystem I: mounting /sys filesystem I: creating /{dev,run}/shm I: mounting /dev/pts filesystem I: redirecting /dev/ptmx to /dev/pts/ptmx I: policy-rc.d already exists I: Copying source file I: copying [pytest-mypy-testing_0.1.3-2.dsc] I: copying [./pytest-mypy-testing_0.1.3.orig.tar.gz] I: copying [./pytest-mypy-testing_0.1.3-2.debian.tar.xz] I: Extracting source dpkg-source: warning: cannot verify inline signature for ./pytest-mypy-testing_0.1.3-2.dsc: no acceptable signature found dpkg-source: info: extracting pytest-mypy-testing in pytest-mypy-testing-0.1.3 dpkg-source: info: unpacking pytest-mypy-testing_0.1.3.orig.tar.gz dpkg-source: info: unpacking pytest-mypy-testing_0.1.3-2.debian.tar.xz I: Not using root during the build. I: Installing the build-deps I: user script /srv/workspace/pbuilder/2991198/tmp/hooks/D02_print_environment starting I: set BUILDDIR='/build/reproducible-path' BUILDUSERGECOS='first user,first room,first work-phone,first home-phone,first other' BUILDUSERNAME='pbuilder1' BUILD_ARCH='arm64' DEBIAN_FRONTEND='noninteractive' DEB_BUILD_OPTIONS='buildinfo=+all reproducible=+all parallel=12 ' DISTRIBUTION='forky' HOME='/root' HOST_ARCH='arm64' IFS=' ' INVOCATION_ID='993b01a03ae748f5965d6122c080f8ac' LANG='C' LANGUAGE='en_US:en' LC_ALL='C' MAIL='/var/mail/root' OPTIND='1' PATH='/usr/sbin:/usr/bin:/sbin:/bin:/usr/games' PBCURRENTCOMMANDLINEOPERATION='build' PBUILDER_OPERATION='build' PBUILDER_PKGDATADIR='/usr/share/pbuilder' PBUILDER_PKGLIBDIR='/usr/lib/pbuilder' PBUILDER_SYSCONFDIR='/etc' PPID='2991198' PS1='# ' PS2='> ' PS4='+ ' PWD='/' SHELL='/bin/bash' SHLVL='2' SUDO_COMMAND='/usr/bin/timeout -k 18.1h 18h /usr/bin/ionice -c 3 /usr/bin/nice /usr/sbin/pbuilder --build --configfile /srv/reproducible-results/rbuild-debian/r-b-build.MSMv6Ms8/pbuilderrc_C7B1 --distribution forky --hookdir /etc/pbuilder/first-build-hooks --debbuildopts -b --basetgz /var/cache/pbuilder/forky-reproducible-base.tgz --buildresult /srv/reproducible-results/rbuild-debian/r-b-build.MSMv6Ms8/b1 --logfile b1/build.log pytest-mypy-testing_0.1.3-2.dsc' SUDO_GID='109' SUDO_HOME='/var/lib/jenkins' SUDO_UID='104' SUDO_USER='jenkins' TERM='unknown' TZ='/usr/share/zoneinfo/Etc/GMT+12' USER='root' _='/usr/bin/systemd-run' http_proxy='http://192.168.101.4:3128' I: uname -a Linux codethink04-arm64 6.12.41+deb13-cloud-arm64 #1 SMP Debian 6.12.41-1 (2025-08-12) aarch64 GNU/Linux I: ls -l /bin lrwxrwxrwx 1 root root 7 Aug 10 12:30 /bin -> usr/bin I: user script /srv/workspace/pbuilder/2991198/tmp/hooks/D02_print_environment finished -> Attempting to satisfy build-dependencies -> Creating pbuilder-satisfydepends-dummy package Package: pbuilder-satisfydepends-dummy Version: 0.invalid.0 Architecture: arm64 Maintainer: Debian Pbuilder Team Description: Dummy package to satisfy dependencies with aptitude - created by pbuilder This package was created automatically by pbuilder to satisfy the build-dependencies of the package being currently built. Depends: debhelper-compat (= 13), dh-sequence-python3, flit, pybuild-plugin-pyproject, python3-all, python3-mypy, python3-pytest dpkg-deb: building package 'pbuilder-satisfydepends-dummy' in '/tmp/satisfydepends-aptitude/pbuilder-satisfydepends-dummy.deb'. Selecting previously unselected package pbuilder-satisfydepends-dummy. (Reading database ... 19969 files and directories currently installed.) Preparing to unpack .../pbuilder-satisfydepends-dummy.deb ... Unpacking pbuilder-satisfydepends-dummy (0.invalid.0) ... dpkg: pbuilder-satisfydepends-dummy: dependency problems, but configuring anyway as you requested: pbuilder-satisfydepends-dummy depends on debhelper-compat (= 13); however: Package debhelper-compat is not installed. pbuilder-satisfydepends-dummy depends on dh-sequence-python3; however: Package dh-sequence-python3 is not installed. pbuilder-satisfydepends-dummy depends on flit; however: Package flit is not installed. pbuilder-satisfydepends-dummy depends on pybuild-plugin-pyproject; however: Package pybuild-plugin-pyproject is not installed. pbuilder-satisfydepends-dummy depends on python3-all; however: Package python3-all is not installed. pbuilder-satisfydepends-dummy depends on python3-mypy; however: Package python3-mypy is not installed. pbuilder-satisfydepends-dummy depends on python3-pytest; however: Package python3-pytest is not installed. Setting up pbuilder-satisfydepends-dummy (0.invalid.0) ... Reading package lists... Building dependency tree... Reading state information... Initializing package states... Writing extended state information... Building tag database... pbuilder-satisfydepends-dummy is already installed at the requested version (0.invalid.0) pbuilder-satisfydepends-dummy is already installed at the requested version (0.invalid.0) The following NEW packages will be installed: autoconf{a} automake{a} autopoint{a} autotools-dev{a} bsdextrautils{a} ca-certificates{a} debhelper{a} dh-autoreconf{a} dh-python{a} dh-strip-nondeterminism{a} docutils-common{a} dwz{a} file{a} flit{a} gettext{a} gettext-base{a} groff-base{a} intltool-debian{a} libarchive-zip-perl{a} libdebhelper-perl{a} libelf1t64{a} libexpat1{a} libffi8{a} libfile-stripnondeterminism-perl{a} libmagic-mgc{a} libmagic1t64{a} libpipeline1{a} libpython3-stdlib{a} libpython3.13-minimal{a} libpython3.13-stdlib{a} libreadline8t64{a} libtool{a} libuchardet0{a} libunistring5{a} libxml2-16{a} m4{a} man-db{a} media-types{a} netbase{a} openssl{a} po-debconf{a} pybuild-plugin-pyproject{a} python3{a} python3-all{a} python3-build{a} python3-certifi{a} python3-chardet{a} python3-charset-normalizer{a} python3-docutils{a} python3-idna{a} python3-iniconfig{a} python3-installer{a} python3-minimal{a} python3-mypy{a} python3-mypy-extensions{a} python3-packaging{a} python3-pathspec{a} python3-pip{a} python3-pluggy{a} python3-psutil{a} python3-pyproject-hooks{a} python3-pytest{a} python3-requests{a} python3-roman{a} python3-tomli-w{a} python3-typing-extensions{a} python3-urllib3{a} python3-wheel{a} python3.13{a} python3.13-minimal{a} readline-common{a} sensible-utils{a} sgml-base{a} tzdata{a} xml-core{a} The following packages are RECOMMENDED but will NOT be installed: curl libarchive-cpio-perl libjs-sphinxdoc libltdl-dev libmail-sendmail-perl libpaper-utils lynx python3-dev python3-lxml python3-orjson python3-pil python3-pygments python3-setuptools wget 0 packages upgraded, 75 newly installed, 0 to remove and 0 not upgraded. Need to get 30.0 MB of archives. After unpacking 150 MB will be used. Writing extended state information... Get: 1 http://deb.debian.org/debian forky/main arm64 libexpat1 arm64 2.7.1-2 [93.3 kB] Get: 2 http://deb.debian.org/debian forky/main arm64 libpython3.13-minimal arm64 3.13.7-1 [857 kB] Get: 3 http://deb.debian.org/debian forky/main arm64 python3.13-minimal arm64 3.13.7-1 [2001 kB] Get: 4 http://deb.debian.org/debian forky/main arm64 python3-minimal arm64 3.13.5-1 [27.2 kB] Get: 5 http://deb.debian.org/debian forky/main arm64 media-types all 13.0.0 [29.3 kB] Get: 6 http://deb.debian.org/debian forky/main arm64 netbase all 6.5 [12.4 kB] Get: 7 http://deb.debian.org/debian forky/main arm64 tzdata all 2025b-5 [260 kB] Get: 8 http://deb.debian.org/debian forky/main arm64 libffi8 arm64 3.4.8-2 [21.3 kB] Get: 9 http://deb.debian.org/debian forky/main arm64 readline-common all 8.2-6 [69.4 kB] Get: 10 http://deb.debian.org/debian forky/main arm64 libreadline8t64 arm64 8.2-6 [159 kB] Get: 11 http://deb.debian.org/debian forky/main arm64 libpython3.13-stdlib arm64 3.13.7-1 [1895 kB] Get: 12 http://deb.debian.org/debian forky/main arm64 python3.13 arm64 3.13.7-1 [761 kB] Get: 13 http://deb.debian.org/debian forky/main arm64 libpython3-stdlib arm64 3.13.5-1 [10.2 kB] Get: 14 http://deb.debian.org/debian forky/main arm64 python3 arm64 3.13.5-1 [28.2 kB] Get: 15 http://deb.debian.org/debian forky/main arm64 sensible-utils all 0.0.26 [27.0 kB] Get: 16 http://deb.debian.org/debian forky/main arm64 openssl arm64 3.5.2-1 [1457 kB] Get: 17 http://deb.debian.org/debian forky/main arm64 ca-certificates all 20250419 [162 kB] Get: 18 http://deb.debian.org/debian forky/main arm64 libmagic-mgc arm64 1:5.46-5 [338 kB] Get: 19 http://deb.debian.org/debian forky/main arm64 libmagic1t64 arm64 1:5.46-5 [103 kB] Get: 20 http://deb.debian.org/debian forky/main arm64 file arm64 1:5.46-5 [43.7 kB] Get: 21 http://deb.debian.org/debian forky/main arm64 gettext-base arm64 0.23.1-2+b1 [241 kB] Get: 22 http://deb.debian.org/debian forky/main arm64 libuchardet0 arm64 0.0.8-1+b2 [69.2 kB] Get: 23 http://deb.debian.org/debian forky/main arm64 groff-base arm64 1.23.0-9 [1130 kB] Get: 24 http://deb.debian.org/debian forky/main arm64 bsdextrautils arm64 2.41.1-1 [93.8 kB] Get: 25 http://deb.debian.org/debian forky/main arm64 libpipeline1 arm64 1.5.8-1 [40.2 kB] Get: 26 http://deb.debian.org/debian forky/main arm64 man-db arm64 2.13.1-1 [1453 kB] Get: 27 http://deb.debian.org/debian forky/main arm64 m4 arm64 1.4.19-8 [285 kB] Get: 28 http://deb.debian.org/debian forky/main arm64 autoconf all 2.72-3.1 [494 kB] Get: 29 http://deb.debian.org/debian forky/main arm64 autotools-dev all 20240727.1 [60.2 kB] Get: 30 http://deb.debian.org/debian forky/main arm64 automake all 1:1.17-4 [862 kB] Get: 31 http://deb.debian.org/debian forky/main arm64 autopoint all 0.23.1-2 [770 kB] Get: 32 http://deb.debian.org/debian forky/main arm64 libdebhelper-perl all 13.25 [91.6 kB] Get: 33 http://deb.debian.org/debian forky/main arm64 libtool all 2.5.4-4 [539 kB] Get: 34 http://deb.debian.org/debian forky/main arm64 dh-autoreconf all 20 [17.1 kB] Get: 35 http://deb.debian.org/debian forky/main arm64 libarchive-zip-perl all 1.68-1 [104 kB] Get: 36 http://deb.debian.org/debian forky/main arm64 libfile-stripnondeterminism-perl all 1.14.2-1 [19.8 kB] Get: 37 http://deb.debian.org/debian forky/main arm64 dh-strip-nondeterminism all 1.14.2-1 [8768 B] Get: 38 http://deb.debian.org/debian forky/main arm64 libelf1t64 arm64 0.192-4 [189 kB] Get: 39 http://deb.debian.org/debian forky/main arm64 dwz arm64 0.15-1+b1 [102 kB] Get: 40 http://deb.debian.org/debian forky/main arm64 libunistring5 arm64 1.3-2 [453 kB] Get: 41 http://deb.debian.org/debian forky/main arm64 libxml2-16 arm64 2.14.5+dfsg-0.1 [583 kB] Get: 42 http://deb.debian.org/debian forky/main arm64 gettext arm64 0.23.1-2+b1 [1612 kB] Get: 43 http://deb.debian.org/debian forky/main arm64 intltool-debian all 0.35.0+20060710.6 [22.9 kB] Get: 44 http://deb.debian.org/debian forky/main arm64 po-debconf all 1.0.21+nmu1 [248 kB] Get: 45 http://deb.debian.org/debian forky/main arm64 debhelper all 13.25 [937 kB] Get: 46 http://deb.debian.org/debian forky/main arm64 dh-python all 6.20250414 [116 kB] Get: 47 http://deb.debian.org/debian forky/main arm64 sgml-base all 1.31+nmu1 [10.9 kB] Get: 48 http://deb.debian.org/debian forky/main arm64 xml-core all 0.19 [20.1 kB] Get: 49 http://deb.debian.org/debian forky/main arm64 docutils-common all 0.21.2+dfsg-2 [128 kB] Get: 50 http://deb.debian.org/debian forky/main arm64 python3-roman all 5.1-1 [11.0 kB] Get: 51 http://deb.debian.org/debian forky/main arm64 python3-docutils all 0.21.2+dfsg-2 [403 kB] Get: 52 http://deb.debian.org/debian forky/main arm64 python3-packaging all 25.0-1 [56.6 kB] Get: 53 http://deb.debian.org/debian forky/main arm64 python3-wheel all 0.46.1-2 [21.7 kB] Get: 54 http://deb.debian.org/debian forky/main arm64 python3-pip all 25.2+dfsg-1 [1386 kB] Get: 55 http://deb.debian.org/debian forky/main arm64 python3-certifi all 2025.1.31+ds-1 [9652 B] Get: 56 http://deb.debian.org/debian forky/main arm64 python3-charset-normalizer arm64 3.4.3-1 [123 kB] Get: 57 http://deb.debian.org/debian forky/main arm64 python3-idna all 3.10-1 [42.0 kB] Get: 58 http://deb.debian.org/debian forky/main arm64 python3-urllib3 all 2.5.0-1 [116 kB] Get: 59 http://deb.debian.org/debian forky/main arm64 python3-chardet all 5.2.0+dfsg-2 [108 kB] Get: 60 http://deb.debian.org/debian forky/main arm64 python3-requests all 2.32.4+dfsg-1 [72.4 kB] Get: 61 http://deb.debian.org/debian forky/main arm64 python3-tomli-w all 1.0.0-3 [8000 B] Get: 62 http://deb.debian.org/debian forky/main arm64 flit all 3.12.0-2 [95.3 kB] Get: 63 http://deb.debian.org/debian forky/main arm64 python3-pyproject-hooks all 1.2.0-1 [11.7 kB] Get: 64 http://deb.debian.org/debian forky/main arm64 python3-build all 1.2.2-4 [36.2 kB] Get: 65 http://deb.debian.org/debian forky/main arm64 python3-installer all 0.7.0+dfsg1-3 [18.6 kB] Get: 66 http://deb.debian.org/debian forky/main arm64 pybuild-plugin-pyproject all 6.20250414 [11.8 kB] Get: 67 http://deb.debian.org/debian forky/main arm64 python3-all arm64 3.13.5-1 [1044 B] Get: 68 http://deb.debian.org/debian forky/main arm64 python3-iniconfig all 1.1.1-2 [6396 B] Get: 69 http://deb.debian.org/debian forky/main arm64 python3-mypy-extensions all 1.1.0-1 [6656 B] Get: 70 http://deb.debian.org/debian forky/main arm64 python3-pathspec all 0.12.1-1 [28.1 kB] Get: 71 http://deb.debian.org/debian forky/main arm64 python3-typing-extensions all 4.14.1-1 [91.3 kB] Get: 72 http://deb.debian.org/debian forky/main arm64 python3-psutil arm64 7.0.0-2 [220 kB] Get: 73 http://deb.debian.org/debian forky/main arm64 python3-mypy arm64 1.17.1-2 [7791 kB] Get: 74 http://deb.debian.org/debian forky/main arm64 python3-pluggy all 1.6.0-1 [27.1 kB] Get: 75 http://deb.debian.org/debian forky/main arm64 python3-pytest all 8.3.5-2 [250 kB] Fetched 30.0 MB in 0s (81.6 MB/s) Preconfiguring packages ... Selecting previously unselected package libexpat1:arm64. (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 19969 files and directories currently installed.) Preparing to unpack .../libexpat1_2.7.1-2_arm64.deb ... Unpacking libexpat1:arm64 (2.7.1-2) ... Selecting previously unselected package libpython3.13-minimal:arm64. Preparing to unpack .../libpython3.13-minimal_3.13.7-1_arm64.deb ... Unpacking libpython3.13-minimal:arm64 (3.13.7-1) ... Selecting previously unselected package python3.13-minimal. Preparing to unpack .../python3.13-minimal_3.13.7-1_arm64.deb ... Unpacking python3.13-minimal (3.13.7-1) ... Setting up libpython3.13-minimal:arm64 (3.13.7-1) ... Setting up libexpat1:arm64 (2.7.1-2) ... Setting up python3.13-minimal (3.13.7-1) ... Selecting previously unselected package python3-minimal. (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 20303 files and directories currently installed.) Preparing to unpack .../0-python3-minimal_3.13.5-1_arm64.deb ... Unpacking python3-minimal (3.13.5-1) ... Selecting previously unselected package media-types. Preparing to unpack .../1-media-types_13.0.0_all.deb ... Unpacking media-types (13.0.0) ... Selecting previously unselected package netbase. Preparing to unpack .../2-netbase_6.5_all.deb ... Unpacking netbase (6.5) ... Selecting previously unselected package tzdata. Preparing to unpack .../3-tzdata_2025b-5_all.deb ... Unpacking tzdata (2025b-5) ... Selecting previously unselected package libffi8:arm64. Preparing to unpack .../4-libffi8_3.4.8-2_arm64.deb ... Unpacking libffi8:arm64 (3.4.8-2) ... Selecting previously unselected package readline-common. Preparing to unpack .../5-readline-common_8.2-6_all.deb ... Unpacking readline-common (8.2-6) ... Selecting previously unselected package libreadline8t64:arm64. Preparing to unpack .../6-libreadline8t64_8.2-6_arm64.deb ... Adding 'diversion of /lib/aarch64-linux-gnu/libhistory.so.8 to /lib/aarch64-linux-gnu/libhistory.so.8.usr-is-merged by libreadline8t64' Adding 'diversion of /lib/aarch64-linux-gnu/libhistory.so.8.2 to /lib/aarch64-linux-gnu/libhistory.so.8.2.usr-is-merged by libreadline8t64' Adding 'diversion of /lib/aarch64-linux-gnu/libreadline.so.8 to /lib/aarch64-linux-gnu/libreadline.so.8.usr-is-merged by libreadline8t64' Adding 'diversion of /lib/aarch64-linux-gnu/libreadline.so.8.2 to /lib/aarch64-linux-gnu/libreadline.so.8.2.usr-is-merged by libreadline8t64' Unpacking libreadline8t64:arm64 (8.2-6) ... Selecting previously unselected package libpython3.13-stdlib:arm64. Preparing to unpack .../7-libpython3.13-stdlib_3.13.7-1_arm64.deb ... Unpacking libpython3.13-stdlib:arm64 (3.13.7-1) ... Selecting previously unselected package python3.13. Preparing to unpack .../8-python3.13_3.13.7-1_arm64.deb ... Unpacking python3.13 (3.13.7-1) ... Selecting previously unselected package libpython3-stdlib:arm64. Preparing to unpack .../9-libpython3-stdlib_3.13.5-1_arm64.deb ... Unpacking libpython3-stdlib:arm64 (3.13.5-1) ... Setting up python3-minimal (3.13.5-1) ... Selecting previously unselected package python3. (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 21318 files and directories currently installed.) Preparing to unpack .../00-python3_3.13.5-1_arm64.deb ... Unpacking python3 (3.13.5-1) ... Selecting previously unselected package sensible-utils. Preparing to unpack .../01-sensible-utils_0.0.26_all.deb ... Unpacking sensible-utils (0.0.26) ... Selecting previously unselected package openssl. Preparing to unpack .../02-openssl_3.5.2-1_arm64.deb ... Unpacking openssl (3.5.2-1) ... Selecting previously unselected package ca-certificates. Preparing to unpack .../03-ca-certificates_20250419_all.deb ... Unpacking ca-certificates (20250419) ... Selecting previously unselected package libmagic-mgc. Preparing to unpack .../04-libmagic-mgc_1%3a5.46-5_arm64.deb ... Unpacking libmagic-mgc (1:5.46-5) ... Selecting previously unselected package libmagic1t64:arm64. Preparing to unpack .../05-libmagic1t64_1%3a5.46-5_arm64.deb ... Unpacking libmagic1t64:arm64 (1:5.46-5) ... Selecting previously unselected package file. Preparing to unpack .../06-file_1%3a5.46-5_arm64.deb ... Unpacking file (1:5.46-5) ... Selecting previously unselected package gettext-base. Preparing to unpack .../07-gettext-base_0.23.1-2+b1_arm64.deb ... Unpacking gettext-base (0.23.1-2+b1) ... Selecting previously unselected package libuchardet0:arm64. Preparing to unpack .../08-libuchardet0_0.0.8-1+b2_arm64.deb ... Unpacking libuchardet0:arm64 (0.0.8-1+b2) ... Selecting previously unselected package groff-base. Preparing to unpack .../09-groff-base_1.23.0-9_arm64.deb ... Unpacking groff-base (1.23.0-9) ... Selecting previously unselected package bsdextrautils. Preparing to unpack .../10-bsdextrautils_2.41.1-1_arm64.deb ... Unpacking bsdextrautils (2.41.1-1) ... Selecting previously unselected package libpipeline1:arm64. Preparing to unpack .../11-libpipeline1_1.5.8-1_arm64.deb ... Unpacking libpipeline1:arm64 (1.5.8-1) ... Selecting previously unselected package man-db. Preparing to unpack .../12-man-db_2.13.1-1_arm64.deb ... Unpacking man-db (2.13.1-1) ... Selecting previously unselected package m4. Preparing to unpack .../13-m4_1.4.19-8_arm64.deb ... Unpacking m4 (1.4.19-8) ... Selecting previously unselected package autoconf. Preparing to unpack .../14-autoconf_2.72-3.1_all.deb ... Unpacking autoconf (2.72-3.1) ... Selecting previously unselected package autotools-dev. Preparing to unpack .../15-autotools-dev_20240727.1_all.deb ... Unpacking autotools-dev (20240727.1) ... Selecting previously unselected package automake. Preparing to unpack .../16-automake_1%3a1.17-4_all.deb ... Unpacking automake (1:1.17-4) ... Selecting previously unselected package autopoint. Preparing to unpack .../17-autopoint_0.23.1-2_all.deb ... Unpacking autopoint (0.23.1-2) ... Selecting previously unselected package libdebhelper-perl. Preparing to unpack .../18-libdebhelper-perl_13.25_all.deb ... Unpacking libdebhelper-perl (13.25) ... Selecting previously unselected package libtool. Preparing to unpack .../19-libtool_2.5.4-4_all.deb ... Unpacking libtool (2.5.4-4) ... Selecting previously unselected package dh-autoreconf. Preparing to unpack .../20-dh-autoreconf_20_all.deb ... Unpacking dh-autoreconf (20) ... Selecting previously unselected package libarchive-zip-perl. Preparing to unpack .../21-libarchive-zip-perl_1.68-1_all.deb ... Unpacking libarchive-zip-perl (1.68-1) ... Selecting previously unselected package libfile-stripnondeterminism-perl. Preparing to unpack .../22-libfile-stripnondeterminism-perl_1.14.2-1_all.deb ... Unpacking libfile-stripnondeterminism-perl (1.14.2-1) ... Selecting previously unselected package dh-strip-nondeterminism. Preparing to unpack .../23-dh-strip-nondeterminism_1.14.2-1_all.deb ... Unpacking dh-strip-nondeterminism (1.14.2-1) ... Selecting previously unselected package libelf1t64:arm64. Preparing to unpack .../24-libelf1t64_0.192-4_arm64.deb ... Unpacking libelf1t64:arm64 (0.192-4) ... Selecting previously unselected package dwz. Preparing to unpack .../25-dwz_0.15-1+b1_arm64.deb ... Unpacking dwz (0.15-1+b1) ... Selecting previously unselected package libunistring5:arm64. Preparing to unpack .../26-libunistring5_1.3-2_arm64.deb ... Unpacking libunistring5:arm64 (1.3-2) ... Selecting previously unselected package libxml2-16:arm64. Preparing to unpack .../27-libxml2-16_2.14.5+dfsg-0.1_arm64.deb ... Unpacking libxml2-16:arm64 (2.14.5+dfsg-0.1) ... Selecting previously unselected package gettext. Preparing to unpack .../28-gettext_0.23.1-2+b1_arm64.deb ... Unpacking gettext (0.23.1-2+b1) ... Selecting previously unselected package intltool-debian. Preparing to unpack .../29-intltool-debian_0.35.0+20060710.6_all.deb ... Unpacking intltool-debian (0.35.0+20060710.6) ... Selecting previously unselected package po-debconf. Preparing to unpack .../30-po-debconf_1.0.21+nmu1_all.deb ... Unpacking po-debconf (1.0.21+nmu1) ... Selecting previously unselected package debhelper. Preparing to unpack .../31-debhelper_13.25_all.deb ... Unpacking debhelper (13.25) ... Selecting previously unselected package dh-python. Preparing to unpack .../32-dh-python_6.20250414_all.deb ... Unpacking dh-python (6.20250414) ... Selecting previously unselected package sgml-base. Preparing to unpack .../33-sgml-base_1.31+nmu1_all.deb ... Unpacking sgml-base (1.31+nmu1) ... Selecting previously unselected package xml-core. Preparing to unpack .../34-xml-core_0.19_all.deb ... Unpacking xml-core (0.19) ... Selecting previously unselected package docutils-common. Preparing to unpack .../35-docutils-common_0.21.2+dfsg-2_all.deb ... Unpacking docutils-common (0.21.2+dfsg-2) ... Selecting previously unselected package python3-roman. Preparing to unpack .../36-python3-roman_5.1-1_all.deb ... Unpacking python3-roman (5.1-1) ... Selecting previously unselected package python3-docutils. Preparing to unpack .../37-python3-docutils_0.21.2+dfsg-2_all.deb ... Unpacking python3-docutils (0.21.2+dfsg-2) ... Selecting previously unselected package python3-packaging. Preparing to unpack .../38-python3-packaging_25.0-1_all.deb ... Unpacking python3-packaging (25.0-1) ... Selecting previously unselected package python3-wheel. Preparing to unpack .../39-python3-wheel_0.46.1-2_all.deb ... Unpacking python3-wheel (0.46.1-2) ... Selecting previously unselected package python3-pip. Preparing to unpack .../40-python3-pip_25.2+dfsg-1_all.deb ... Unpacking python3-pip (25.2+dfsg-1) ... Selecting previously unselected package python3-certifi. Preparing to unpack .../41-python3-certifi_2025.1.31+ds-1_all.deb ... Unpacking python3-certifi (2025.1.31+ds-1) ... Selecting previously unselected package python3-charset-normalizer. Preparing to unpack .../42-python3-charset-normalizer_3.4.3-1_arm64.deb ... Unpacking python3-charset-normalizer (3.4.3-1) ... Selecting previously unselected package python3-idna. Preparing to unpack .../43-python3-idna_3.10-1_all.deb ... Unpacking python3-idna (3.10-1) ... Selecting previously unselected package python3-urllib3. Preparing to unpack .../44-python3-urllib3_2.5.0-1_all.deb ... Unpacking python3-urllib3 (2.5.0-1) ... Selecting previously unselected package python3-chardet. Preparing to unpack .../45-python3-chardet_5.2.0+dfsg-2_all.deb ... Unpacking python3-chardet (5.2.0+dfsg-2) ... Selecting previously unselected package python3-requests. Preparing to unpack .../46-python3-requests_2.32.4+dfsg-1_all.deb ... Unpacking python3-requests (2.32.4+dfsg-1) ... Selecting previously unselected package python3-tomli-w. Preparing to unpack .../47-python3-tomli-w_1.0.0-3_all.deb ... Unpacking python3-tomli-w (1.0.0-3) ... Selecting previously unselected package flit. Preparing to unpack .../48-flit_3.12.0-2_all.deb ... Unpacking flit (3.12.0-2) ... Selecting previously unselected package python3-pyproject-hooks. Preparing to unpack .../49-python3-pyproject-hooks_1.2.0-1_all.deb ... Unpacking python3-pyproject-hooks (1.2.0-1) ... Selecting previously unselected package python3-build. Preparing to unpack .../50-python3-build_1.2.2-4_all.deb ... Unpacking python3-build (1.2.2-4) ... Selecting previously unselected package python3-installer. Preparing to unpack .../51-python3-installer_0.7.0+dfsg1-3_all.deb ... Unpacking python3-installer (0.7.0+dfsg1-3) ... Selecting previously unselected package pybuild-plugin-pyproject. Preparing to unpack .../52-pybuild-plugin-pyproject_6.20250414_all.deb ... Unpacking pybuild-plugin-pyproject (6.20250414) ... Selecting previously unselected package python3-all. Preparing to unpack .../53-python3-all_3.13.5-1_arm64.deb ... Unpacking python3-all (3.13.5-1) ... Selecting previously unselected package python3-iniconfig. Preparing to unpack .../54-python3-iniconfig_1.1.1-2_all.deb ... Unpacking python3-iniconfig (1.1.1-2) ... Selecting previously unselected package python3-mypy-extensions. Preparing to unpack .../55-python3-mypy-extensions_1.1.0-1_all.deb ... Unpacking python3-mypy-extensions (1.1.0-1) ... Selecting previously unselected package python3-pathspec. Preparing to unpack .../56-python3-pathspec_0.12.1-1_all.deb ... Unpacking python3-pathspec (0.12.1-1) ... Selecting previously unselected package python3-typing-extensions. Preparing to unpack .../57-python3-typing-extensions_4.14.1-1_all.deb ... Unpacking python3-typing-extensions (4.14.1-1) ... Selecting previously unselected package python3-psutil. Preparing to unpack .../58-python3-psutil_7.0.0-2_arm64.deb ... Unpacking python3-psutil (7.0.0-2) ... Selecting previously unselected package python3-mypy. Preparing to unpack .../59-python3-mypy_1.17.1-2_arm64.deb ... Unpacking python3-mypy (1.17.1-2) ... Selecting previously unselected package python3-pluggy. Preparing to unpack .../60-python3-pluggy_1.6.0-1_all.deb ... Unpacking python3-pluggy (1.6.0-1) ... Selecting previously unselected package python3-pytest. Preparing to unpack .../61-python3-pytest_8.3.5-2_all.deb ... Unpacking python3-pytest (8.3.5-2) ... Setting up media-types (13.0.0) ... Setting up libpipeline1:arm64 (1.5.8-1) ... Setting up bsdextrautils (2.41.1-1) ... Setting up libmagic-mgc (1:5.46-5) ... Setting up libarchive-zip-perl (1.68-1) ... Setting up libxml2-16:arm64 (2.14.5+dfsg-0.1) ... Setting up libdebhelper-perl (13.25) ... Setting up libmagic1t64:arm64 (1:5.46-5) ... Setting up gettext-base (0.23.1-2+b1) ... Setting up m4 (1.4.19-8) ... Setting up file (1:5.46-5) ... Setting up libelf1t64:arm64 (0.192-4) ... Setting up tzdata (2025b-5) ... Current default time zone: 'Etc/UTC' Local time is now: Thu Aug 28 19:55:31 UTC 2025. Universal Time is now: Thu Aug 28 19:55:31 UTC 2025. Run 'dpkg-reconfigure tzdata' if you wish to change it. Setting up autotools-dev (20240727.1) ... Setting up libunistring5:arm64 (1.3-2) ... Setting up autopoint (0.23.1-2) ... Setting up autoconf (2.72-3.1) ... Setting up libffi8:arm64 (3.4.8-2) ... Setting up dwz (0.15-1+b1) ... Setting up sensible-utils (0.0.26) ... Setting up libuchardet0:arm64 (0.0.8-1+b2) ... Setting up netbase (6.5) ... Setting up sgml-base (1.31+nmu1) ... Setting up openssl (3.5.2-1) ... Setting up readline-common (8.2-6) ... Setting up automake (1:1.17-4) ... update-alternatives: using /usr/bin/automake-1.17 to provide /usr/bin/automake (automake) in auto mode Setting up libfile-stripnondeterminism-perl (1.14.2-1) ... Setting up gettext (0.23.1-2+b1) ... Setting up libtool (2.5.4-4) ... Setting up intltool-debian (0.35.0+20060710.6) ... Setting up dh-autoreconf (20) ... Setting up ca-certificates (20250419) ... Updating certificates in /etc/ssl/certs... 150 added, 0 removed; done. Setting up libreadline8t64:arm64 (8.2-6) ... Setting up dh-strip-nondeterminism (1.14.2-1) ... Setting up groff-base (1.23.0-9) ... Setting up xml-core (0.19) ... Setting up libpython3.13-stdlib:arm64 (3.13.7-1) ... Setting up libpython3-stdlib:arm64 (3.13.5-1) ... Setting up python3.13 (3.13.7-1) ... Setting up po-debconf (1.0.21+nmu1) ... Setting up python3 (3.13.5-1) ... Setting up man-db (2.13.1-1) ... Not building database; man-db/auto-update is not 'true'. Setting up python3-psutil (7.0.0-2) ... Setting up python3-roman (5.1-1) ... Setting up python3-packaging (25.0-1) ... Setting up python3-chardet (5.2.0+dfsg-2) ... Setting up python3-pyproject-hooks (1.2.0-1) ... Setting up python3-certifi (2025.1.31+ds-1) ... Setting up python3-idna (3.10-1) ... Setting up python3-typing-extensions (4.14.1-1) ... Setting up python3-installer (0.7.0+dfsg1-3) ... Setting up python3-urllib3 (2.5.0-1) ... Setting up python3-pluggy (1.6.0-1) ... Setting up python3-pathspec (0.12.1-1) ... Setting up python3-tomli-w (1.0.0-3) ... Setting up dh-python (6.20250414) ... Setting up python3-iniconfig (1.1.1-2) ... Setting up python3-charset-normalizer (3.4.3-1) ... Setting up python3-pytest (8.3.5-2) ... Setting up python3-mypy-extensions (1.1.0-1) ... Setting up python3-all (3.13.5-1) ... Setting up debhelper (13.25) ... Setting up python3-wheel (0.46.1-2) ... Setting up python3-requests (2.32.4+dfsg-1) ... Setting up python3-mypy (1.17.1-2) ... Setting up python3-pip (25.2+dfsg-1) ... Setting up python3-build (1.2.2-4) ... Setting up pybuild-plugin-pyproject (6.20250414) ... Processing triggers for libc-bin (2.41-12) ... Processing triggers for sgml-base (1.31+nmu1) ... Setting up docutils-common (0.21.2+dfsg-2) ... Processing triggers for sgml-base (1.31+nmu1) ... Setting up python3-docutils (0.21.2+dfsg-2) ... Setting up flit (3.12.0-2) ... Processing triggers for ca-certificates (20250419) ... Updating certificates in /etc/ssl/certs... 0 added, 0 removed; done. Running hooks in /etc/ca-certificates/update.d... done. Reading package lists... Building dependency tree... Reading state information... Reading extended state information... Initializing package states... Writing extended state information... Building tag database... -> Finished parsing the build-deps I: Building the package I: Running cd /build/reproducible-path/pytest-mypy-testing-0.1.3/ && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games" HOME="/nonexistent/first-build" dpkg-buildpackage -us -uc -b && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games" HOME="/nonexistent/first-build" dpkg-genchanges -S > ../pytest-mypy-testing_0.1.3-2_source.changes dpkg-buildpackage: info: source package pytest-mypy-testing dpkg-buildpackage: info: source version 0.1.3-2 dpkg-buildpackage: info: source distribution unstable dpkg-buildpackage: info: source changed by Julian Gilbey dpkg-source --before-build . dpkg-buildpackage: info: host architecture arm64 debian/rules clean dh clean --buildsystem=pybuild dh_auto_clean -O--buildsystem=pybuild dh_autoreconf_clean -O--buildsystem=pybuild dh_clean -O--buildsystem=pybuild 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 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 /build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13 * Building wheel... Successfully built pytest_mypy_testing-0.1.3-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 /build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build; python3.13 -m pytest tests ============================= test session starts ============================== platform linux -- Python 3.13.7, pytest-8.3.5, pluggy-1.6.0 -- /usr/bin/python3.13 cachedir: .pytest_cache rootdir: /build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build configfile: pytest.ini collecting ... collected 69 items run-last-failure: no previously failed tests, not deselecting items. tests/test___init__.py::test_version PASSED [ 1%] tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment FAILED [ 2%] tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_with_error_code FAILED [ 4%] tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_with_error_code__message_does_not_match XFAIL [ 5%] tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_only_error_code FAILED [ 7%] tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_only_error_code__error_code_does_not_match XFAIL [ 8%] tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_no_message_and_no_error_code XFAIL [ 10%] tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type FAILED [ 11%] tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__float_var FAILED [ 13%] tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__int_var FAILED [ 14%] tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__int_list_var FAILED [ 15%] tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__int_list_var__with__inferred_asterisk FAILED [ 17%] tests/test_basics.mypy-testing::[mypy]mypy_test_use_skip_marker SKIPPED [ 18%] tests/test_basics.mypy-testing::[mypy]mypy_test_xfail_wrong_reveal_type XFAIL [ 20%] tests/test_basics.mypy-testing::[mypy]mypy_test_xfail_missing_note XFAIL [ 21%] tests/test_basics.mypy-testing::[mypy]mypy_test_xfail_unexpected_note XFAIL [ 23%] tests/test_file_with_nonitem_messages.mypy-testing::[mypy]mypy_test_xfail_unexpected_note XFAIL [ 24%] tests/test_message.py::test_init_severity[r-note] PASSED [ 26%] tests/test_message.py::test_init_severity[N-note] PASSED [ 27%] tests/test_message.py::test_message_from_comment[z.py-# E: bar-error-bar-None] PASSED [ 28%] tests/test_message.py::test_message_from_comment[z.py-# E: bar-error-bar-foo] PASSED [ 30%] tests/test_message.py::test_message_from_comment[z.py-# E: bar [foo]-error-bar-foo] PASSED [ 31%] tests/test_message.py::test_message_from_comment[z.py-# E: bar [foo]-error-bar-] PASSED [ 33%] tests/test_message.py::test_message_from_comment[z.py-#type:ignore# W: bar-warning-bar-None] PASSED [ 34%] tests/test_message.py::test_message_from_comment[z.py-# type: ignore # W: bar-warning-bar-None] PASSED [ 36%] tests/test_message.py::test_message_from_comment[z.py-# R: bar-note-Revealed type is 'bar'-None] PASSED [ 37%] tests/test_message.py::test_message_from_invalid_comment PASSED [ 39%] tests/test_message.py::test_message_from_output[z.py:1: note: bar-note-bar] PASSED [ 40%] tests/test_message.py::test_message_from_output[z.py:1:2: note: bar-note-bar] PASSED [ 42%] tests/test_message.py::test_message_from_output[z.py:1:2: error: fubar-error-fubar] PASSED [ 43%] tests/test_message.py::test_message_from_invalid_output[foo.py:a: fubar] PASSED [ 44%] tests/test_message.py::test_message_from_invalid_output[fubar] PASSED [ 46%] tests/test_message.py::test_message_from_invalid_output[foo.py:1: fubar] PASSED [ 47%] tests/test_message.py::test_message_from_invalid_output[foo.py:1:1: fubar] PASSED [ 49%] tests/test_message.py::test_message_from_invalid_output[foo.py:1:1: not: fubar] PASSED [ 50%] tests/test_message.py::test_message_eq[a0-b0] PASSED [ 52%] tests/test_message.py::test_message_eq[a1-b1] PASSED [ 53%] tests/test_message.py::test_message_eq[a2-b2] PASSED [ 55%] tests/test_message.py::test_message_eq[a3-b3] PASSED [ 56%] tests/test_message.py::test_message_neq_with_not_message PASSED [ 57%] tests/test_message.py::test_message_hash PASSED [ 59%] tests/test_message.py::test_message_str PASSED [ 60%] tests/test_output_processing.py::test_output_mismatch_neither_actual_nor_expected PASSED [ 62%] tests/test_output_processing.py::test_output_mismatch_actual_lineno_or_severity_without_actual PASSED [ 63%] tests/test_output_processing.py::test_output_mismatch_expected_lineno_or_severity_without_expected PASSED [ 65%] tests/test_output_processing.py::test_output_mismatch_line_number_mismatch PASSED [ 66%] tests/test_output_processing.py::test_output_mismatch_with_actual_and_expected PASSED [ 68%] tests/test_output_processing.py::test_output_mismatch_only_expected PASSED [ 69%] tests/test_output_processing.py::test_output_mismatch_only_actual PASSED [ 71%] tests/test_output_processing.py::test_iter_diff_sequences PASSED [ 72%] tests/test_output_processing.py::test_diff_message_sequences PASSED [ 73%] tests/test_parser.py::test_cannot_create_mypy_test_case_from_ast_node_without_valid_node[None] PASSED [ 75%] tests/test_parser.py::test_cannot_create_mypy_test_case_from_ast_node_without_valid_node[123] PASSED [ 76%] tests/test_parser.py::test_cannot_create_mypy_test_case_from_ast_node_without_valid_node[abc] PASSED [ 78%] tests/test_parser.py::test_create_mypy_test_case PASSED [ 79%] tests/test_parser.py::test_iter_comments PASSED [ 81%] tests/test_parser.py::test_parse_file_basic_call_works_with_py37 PASSED [ 82%] tests/test_parser.py::test_parse_async PASSED [ 84%] tests/test_plugin.py::test_create_mypy_assertion_error PASSED [ 85%] tests/test_plugin.py::test_pytest_collect_file_not_test_file_name[z.py] PASSED [ 86%] tests/test_plugin.py::test_pytest_collect_file_not_test_file_name[test_z.mypy-testing] PASSED [ 88%] tests/test_plugin.py::test_pytest_collect_file[test_z.py] PASSED [ 89%] tests/test_plugin.py::test_pytest_collect_file[test_z.mypy-testing] PASSED [ 91%] tests/test_strutil.py::test_common_prefix[--] PASSED [ 92%] tests/test_strutil.py::test_common_prefix[a-a-a] PASSED [ 94%] tests/test_strutil.py::test_common_prefix[abc-abcd-abc] PASSED [ 95%] tests/test_strutil.py::test_common_prefix[abcd-abc-abc] PASSED [ 97%] tests/test_strutil.py::test_common_prefix[abc-xyz-] PASSED [ 98%] tests/test_strutil.py::test_dedent PASSED [100%] =================================== FAILURES =================================== ______________________ [mypy]mypy_test_invalid_assignment ______________________ cls = func = . at 0xffff869d7880> when = 'call' reraise = (, ) @classmethod def from_call( cls, func: Callable[[], TResult], when: Literal["collect", "setup", "call", "teardown"], reraise: type[BaseException] | tuple[type[BaseException], ...] | None = None, ) -> CallInfo[TResult]: """Call func, wrapping the result in a CallInfo. :param func: The function to call. Called without arguments. :type func: Callable[[], _pytest.runner.TResult] :param when: The phase in which the function is called. :param reraise: Exception or exceptions that shall propagate if raised by the function, instead of being wrapped in the CallInfo. """ excinfo = None start = timing.time() precise_start = timing.perf_counter() try: > result: TResult | None = func() cls = duration = 11.834927721996792 excinfo = func = . at 0xffff869d7880> precise_start = 696304.301577092 precise_stop = 696316.136504814 reraise = (, ) result = None start = 1756410962.8100798 stop = 1756410974.6450095 when = 'call' /usr/lib/python3/dist-packages/_pytest/runner.py:341: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise ) item = kwds = {} runtest_hook = /usr/lib/python3/dist-packages/_pytest/runner.py:242: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = kwargs = {'item': } firstresult = False def __call__(self, **kwargs: object) -> Any: """Call the hook. Only accepts keyword arguments, which should match the hook specification. Returns the result(s) of calling all registered plugins, see :ref:`calling`. """ assert not self.is_historic(), ( "Cannot directly call a historic hook - use call_historic instead." ) self._verify_all_args_are_provided(kwargs) firstresult = self.spec.opts.get("firstresult", False) if self.spec else False # Copy because plugins may register other plugins during iteration (#438). > return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) firstresult = False kwargs = {'item': } self = /usr/lib/python3/dist-packages/pluggy/_hooks.py:512: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> hook_name = 'pytest_runtest_call' methods = [>] kwargs = {'item': } firstresult = False def _hookexec( self, hook_name: str, methods: Sequence[HookImpl], kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: # called from all hookcaller instances. # enable_tracing will set its own wrapping function at self._inner_hookexec > return self._inner_hookexec(hook_name, methods, kwargs, firstresult) firstresult = False hook_name = 'pytest_runtest_call' kwargs = {'item': } methods = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> /usr/lib/python3/dist-packages/pluggy/_manager.py:120: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: teardown.throw(exception) except RuntimeError as re: # StopIteration from generator causes RuntimeError # even for coroutine usage - see #544 if ( isinstance(exception, StopIteration) and re.__cause__ is exception ): teardown.close() continue else: raise else: teardown.send(result) # Following is unreachable for a well behaved hook wrapper. # Try to force finalizers otherwise postponed till GC action. # Note: close() may raise if generator handles GeneratorExit. teardown.close() except StopIteration as si: result = si.value exception = None continue except BaseException as e: exception = e continue _raise_wrapfail(teardown, "has second yield") if exception is not None: > raise exception __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:167: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from thread_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/threadexception.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def thread_exception_runtest_hook() -> Generator[None]: with catch_threading_exception() as cm: try: > yield cm = <_pytest.threadexception.catch_threading_exception object at 0xffff87401350> /usr/lib/python3/dist-packages/_pytest/threadexception.py:68: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from unraisable_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:95: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def unraisable_exception_runtest_hook() -> Generator[None]: with catch_unraisable_exception() as cm: try: > yield cm = <_pytest.unraisableexception.catch_unraisable_exception object at 0xffff8690ac40> /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:70: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: nodes.Item) -> Generator[None]: self.log_cli_handler.set_when("call") > yield from self._runtest_for(item, "call") item = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> /usr/lib/python3/dist-packages/_pytest/logging.py:846: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = , when = 'call' def _runtest_for(self, item: nodes.Item, when: str) -> Generator[None]: """Implement the internals of the pytest_runtest_xxx() hooks.""" with catching_logs( self.caplog_handler, level=self.log_level, ) as caplog_handler, catching_logs( self.report_handler, level=self.log_level, ) as report_handler: caplog_handler.reset() report_handler.reset() item.stash[caplog_records_key][when] = caplog_handler.records item.stash[caplog_handler_key] = caplog_handler try: > yield caplog_handler = item = log = '' report_handler = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> when = 'call' /usr/lib/python3/dist-packages/_pytest/logging.py:829: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = > _state='suspended' _in_suspended=False> _capture_fixture=None> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: Item) -> Generator[None]: with self.item_capture("call", item): > return (yield) item = self = > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None> /usr/lib/python3/dist-packages/_pytest/capture.py:898: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = @hookimpl(wrapper=True) def pytest_runtest_call(item: Item) -> Generator[None]: xfailed = item.stash.get(xfailed_key, None) if xfailed is None: item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) if xfailed and not item.config.option.runxfail and not xfailed.run: xfail("[NOTRUN] " + xfailed.reason) try: > return (yield) item = xfailed = None /usr/lib/python3/dist-packages/_pytest/skipping.py:257: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: > res = hook_impl.function(*args) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:121: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = def pytest_runtest_call(item: Item) -> None: _update_current_test_var(item, "call") try: del sys.last_type del sys.last_value del sys.last_traceback if sys.version_info >= (3, 12, 0): del sys.last_exc # type:ignore[attr-defined] except AttributeError: pass try: > item.runtest() item = /usr/lib/python3/dist-packages/_pytest/runner.py:174: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def runtest(self) -> None: > returncode, actual_messages = self.parent.run_mypy(self.mypy_item) self = pytest_mypy_testing/plugin.py:64: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = item = MypyTestItem(name='mypy_test_invalid_assignment', lineno=8, end_lineno=11, expected_messages=[Message(filename='/build...e, error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) def run_mypy(self, item: MypyTestItem) -> Tuple[int, List[Message]]: if self._mypy_result is None: > self._mypy_result = self._run_mypy(self.path) item = MypyTestItem(name='mypy_test_invalid_assignment', lineno=8, end_lineno=11, expected_messages=[Message(filename='/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing', lineno=11, colno=None, severity=Severity.ERROR, message='Incompatible types in ' 'assignment (expression has ' 'type "int", variable has type ' '"str")', revealed_type=None, error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) self = pytest_mypy_testing/plugin.py:136: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') def _run_mypy(self, filename: Union[pathlib.Path, os.PathLike, str]) -> MypyResult: filename = pathlib.Path(filename) with tempfile.TemporaryDirectory(prefix="pytest-mypy-testing-") as tmp_dir_name: mypy_cache_dir = os.path.join(tmp_dir_name, "mypy_cache") os.makedirs(mypy_cache_dir) mypy_args = [ "--cache-dir={}".format(mypy_cache_dir), "--check-untyped-defs", "--hide-error-context", "--no-color-output", "--no-error-summary", "--no-pretty", "--soft-error-limit=-1", "--no-silence-site-packages", "--no-warn-unused-configs", "--show-column-numbers", "--show-error-codes", "--show-traceback", str(filename), ] out, err, returncode = mypy.api.run(mypy_args) lines = (out + err).splitlines() file_messages = [ msg > for msg in map(Message.from_output, lines) if (msg.filename == self.mypy_file.filename) and not ( msg.severity is Severity.NOTE and msg.message == "See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports" ) ] err = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)\n') filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') lines = ['tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:49:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:50:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"', 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"', 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:80:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:81:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:87:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"', '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)'] mypy_args = ['--cache-dir=/tmp/pytest-mypy-testing-hav8ncex/mypy_cache', '--check-untyped-defs', '--hide-error-context', '--no-color-output', '--no-error-summary', '--no-pretty', '--soft-error-limit=-1', '--no-silence-site-packages', '--no-warn-unused-configs', '--show-column-numbers', '--show-error-codes', '--show-traceback', '/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing'] mypy_cache_dir = '/tmp/pytest-mypy-testing-hav8ncex/mypy_cache' out = ('tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:49:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:50:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"\n' 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"\n' 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:80:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:81:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:87:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"\n') returncode = 1 self = tmp_dir_name = '/tmp/pytest-mypy-testing-hav8ncex' pytest_mypy_testing/plugin.py:173: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ cls = line = '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must be 3.9 or higher)' @classmethod def from_output(cls, line: str) -> "Message": """Create message object from mypy output line. >>> m = Message.from_output("z.py:1: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1:13: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1: note: Revealed type is 'bar'") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, "Revealed type is 'bar'", 'bar', None) >>> m = Message.from_output('z.py:1: note: Revealed type is "bar"') >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'Revealed type is "bar"', 'bar', None) >>> m = Message.from_output("z.py:1:13: error: bar [baz]") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.ERROR, 'bar', None, 'baz') """ m = cls.OUTPUT_RE.match(line) if not m: > raise ValueError("Not a valid mypy message") E ValueError: Not a valid mypy message cls = line = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)') m = None pytest_mypy_testing/message.py:295: ValueError ______________ [mypy]mypy_test_invalid_assignment_with_error_code ______________ cls = func = . at 0xffff827300e0> when = 'call' reraise = (, ) @classmethod def from_call( cls, func: Callable[[], TResult], when: Literal["collect", "setup", "call", "teardown"], reraise: type[BaseException] | tuple[type[BaseException], ...] | None = None, ) -> CallInfo[TResult]: """Call func, wrapping the result in a CallInfo. :param func: The function to call. Called without arguments. :type func: Callable[[], _pytest.runner.TResult] :param when: The phase in which the function is called. :param reraise: Exception or exceptions that shall propagate if raised by the function, instead of being wrapped in the CallInfo. """ excinfo = None start = timing.time() precise_start = timing.perf_counter() try: > result: TResult | None = func() cls = duration = 11.618835762958042 excinfo = func = . at 0xffff827300e0> precise_start = 696316.321029761 precise_stop = 696327.939865524 reraise = (, ) result = None start = 1756410974.8295329 stop = 1756410986.44837 when = 'call' /usr/lib/python3/dist-packages/_pytest/runner.py:341: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise ) item = kwds = {} runtest_hook = /usr/lib/python3/dist-packages/_pytest/runner.py:242: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = kwargs = {'item': } firstresult = False def __call__(self, **kwargs: object) -> Any: """Call the hook. Only accepts keyword arguments, which should match the hook specification. Returns the result(s) of calling all registered plugins, see :ref:`calling`. """ assert not self.is_historic(), ( "Cannot directly call a historic hook - use call_historic instead." ) self._verify_all_args_are_provided(kwargs) firstresult = self.spec.opts.get("firstresult", False) if self.spec else False # Copy because plugins may register other plugins during iteration (#438). > return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) firstresult = False kwargs = {'item': } self = /usr/lib/python3/dist-packages/pluggy/_hooks.py:512: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> hook_name = 'pytest_runtest_call' methods = [>] kwargs = {'item': } firstresult = False def _hookexec( self, hook_name: str, methods: Sequence[HookImpl], kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: # called from all hookcaller instances. # enable_tracing will set its own wrapping function at self._inner_hookexec > return self._inner_hookexec(hook_name, methods, kwargs, firstresult) firstresult = False hook_name = 'pytest_runtest_call' kwargs = {'item': } methods = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> /usr/lib/python3/dist-packages/pluggy/_manager.py:120: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: teardown.throw(exception) except RuntimeError as re: # StopIteration from generator causes RuntimeError # even for coroutine usage - see #544 if ( isinstance(exception, StopIteration) and re.__cause__ is exception ): teardown.close() continue else: raise else: teardown.send(result) # Following is unreachable for a well behaved hook wrapper. # Try to force finalizers otherwise postponed till GC action. # Note: close() may raise if generator handles GeneratorExit. teardown.close() except StopIteration as si: result = si.value exception = None continue except BaseException as e: exception = e continue _raise_wrapfail(teardown, "has second yield") if exception is not None: > raise exception __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:167: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from thread_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/threadexception.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def thread_exception_runtest_hook() -> Generator[None]: with catch_threading_exception() as cm: try: > yield cm = <_pytest.threadexception.catch_threading_exception object at 0xffff821daf10> /usr/lib/python3/dist-packages/_pytest/threadexception.py:68: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from unraisable_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:95: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def unraisable_exception_runtest_hook() -> Generator[None]: with catch_unraisable_exception() as cm: try: > yield cm = <_pytest.unraisableexception.catch_unraisable_exception object at 0xffff821db8a0> /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:70: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: nodes.Item) -> Generator[None]: self.log_cli_handler.set_when("call") > yield from self._runtest_for(item, "call") item = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> /usr/lib/python3/dist-packages/_pytest/logging.py:846: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = when = 'call' def _runtest_for(self, item: nodes.Item, when: str) -> Generator[None]: """Implement the internals of the pytest_runtest_xxx() hooks.""" with catching_logs( self.caplog_handler, level=self.log_level, ) as caplog_handler, catching_logs( self.report_handler, level=self.log_level, ) as report_handler: caplog_handler.reset() report_handler.reset() item.stash[caplog_records_key][when] = caplog_handler.records item.stash[caplog_handler_key] = caplog_handler try: > yield caplog_handler = item = log = '' report_handler = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> when = 'call' /usr/lib/python3/dist-packages/_pytest/logging.py:829: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = > _state='suspended' _in_suspended=False> _capture_fixture=None> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: Item) -> Generator[None]: with self.item_capture("call", item): > return (yield) item = self = > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None> /usr/lib/python3/dist-packages/_pytest/capture.py:898: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = @hookimpl(wrapper=True) def pytest_runtest_call(item: Item) -> Generator[None]: xfailed = item.stash.get(xfailed_key, None) if xfailed is None: item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) if xfailed and not item.config.option.runxfail and not xfailed.run: xfail("[NOTRUN] " + xfailed.reason) try: > return (yield) item = xfailed = None /usr/lib/python3/dist-packages/_pytest/skipping.py:257: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: > res = hook_impl.function(*args) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:121: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = def pytest_runtest_call(item: Item) -> None: _update_current_test_var(item, "call") try: del sys.last_type del sys.last_value del sys.last_traceback if sys.version_info >= (3, 12, 0): del sys.last_exc # type:ignore[attr-defined] except AttributeError: pass try: > item.runtest() item = /usr/lib/python3/dist-packages/_pytest/runner.py:174: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def runtest(self) -> None: > returncode, actual_messages = self.parent.run_mypy(self.mypy_item) self = pytest_mypy_testing/plugin.py:64: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = item = MypyTestItem(name='mypy_test_invalid_assignment_with_error_code', lineno=14, end_lineno=17, expected_messages=[Message..._code='assignment')], func_node=, marks={'mypy_testing'}, actual_messages=[]) def run_mypy(self, item: MypyTestItem) -> Tuple[int, List[Message]]: if self._mypy_result is None: > self._mypy_result = self._run_mypy(self.path) item = MypyTestItem(name='mypy_test_invalid_assignment_with_error_code', lineno=14, end_lineno=17, expected_messages=[Message(filename='/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing', lineno=17, colno=None, severity=Severity.ERROR, message='Incompatible types in ' 'assignment (expression has ' 'type "int", variable has type ' '"str")', revealed_type=None, error_code='assignment')], func_node=, marks={'mypy_testing'}, actual_messages=[]) self = pytest_mypy_testing/plugin.py:136: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') def _run_mypy(self, filename: Union[pathlib.Path, os.PathLike, str]) -> MypyResult: filename = pathlib.Path(filename) with tempfile.TemporaryDirectory(prefix="pytest-mypy-testing-") as tmp_dir_name: mypy_cache_dir = os.path.join(tmp_dir_name, "mypy_cache") os.makedirs(mypy_cache_dir) mypy_args = [ "--cache-dir={}".format(mypy_cache_dir), "--check-untyped-defs", "--hide-error-context", "--no-color-output", "--no-error-summary", "--no-pretty", "--soft-error-limit=-1", "--no-silence-site-packages", "--no-warn-unused-configs", "--show-column-numbers", "--show-error-codes", "--show-traceback", str(filename), ] out, err, returncode = mypy.api.run(mypy_args) lines = (out + err).splitlines() file_messages = [ msg > for msg in map(Message.from_output, lines) if (msg.filename == self.mypy_file.filename) and not ( msg.severity is Severity.NOTE and msg.message == "See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports" ) ] err = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)\n') filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') lines = ['tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:49:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:50:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"', 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"', 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:80:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:81:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:87:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"', '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)'] mypy_args = ['--cache-dir=/tmp/pytest-mypy-testing-bs85mfta/mypy_cache', '--check-untyped-defs', '--hide-error-context', '--no-color-output', '--no-error-summary', '--no-pretty', '--soft-error-limit=-1', '--no-silence-site-packages', '--no-warn-unused-configs', '--show-column-numbers', '--show-error-codes', '--show-traceback', '/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing'] mypy_cache_dir = '/tmp/pytest-mypy-testing-bs85mfta/mypy_cache' out = ('tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:49:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:50:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"\n' 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"\n' 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:80:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:81:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:87:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"\n') returncode = 1 self = tmp_dir_name = '/tmp/pytest-mypy-testing-bs85mfta' pytest_mypy_testing/plugin.py:173: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ cls = line = '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must be 3.9 or higher)' @classmethod def from_output(cls, line: str) -> "Message": """Create message object from mypy output line. >>> m = Message.from_output("z.py:1: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1:13: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1: note: Revealed type is 'bar'") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, "Revealed type is 'bar'", 'bar', None) >>> m = Message.from_output('z.py:1: note: Revealed type is "bar"') >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'Revealed type is "bar"', 'bar', None) >>> m = Message.from_output("z.py:1:13: error: bar [baz]") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.ERROR, 'bar', None, 'baz') """ m = cls.OUTPUT_RE.match(line) if not m: > raise ValueError("Not a valid mypy message") E ValueError: Not a valid mypy message cls = line = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)') m = None pytest_mypy_testing/message.py:295: ValueError ______________ [mypy]mypy_test_invalid_assignment_only_error_code ______________ cls = func = . at 0xffff82704220> when = 'call' reraise = (, ) @classmethod def from_call( cls, func: Callable[[], TResult], when: Literal["collect", "setup", "call", "teardown"], reraise: type[BaseException] | tuple[type[BaseException], ...] | None = None, ) -> CallInfo[TResult]: """Call func, wrapping the result in a CallInfo. :param func: The function to call. Called without arguments. :type func: Callable[[], _pytest.runner.TResult] :param when: The phase in which the function is called. :param reraise: Exception or exceptions that shall propagate if raised by the function, instead of being wrapped in the CallInfo. """ excinfo = None start = timing.time() precise_start = timing.perf_counter() try: > result: TResult | None = func() cls = duration = 15.925029920064844 excinfo = func = . at 0xffff82704220> precise_start = 696341.099479853 precise_stop = 696357.024509773 reraise = (, ) result = None start = 1756410999.607983 stop = 1756411015.5330143 when = 'call' /usr/lib/python3/dist-packages/_pytest/runner.py:341: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise ) item = kwds = {} runtest_hook = /usr/lib/python3/dist-packages/_pytest/runner.py:242: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = kwargs = {'item': } firstresult = False def __call__(self, **kwargs: object) -> Any: """Call the hook. Only accepts keyword arguments, which should match the hook specification. Returns the result(s) of calling all registered plugins, see :ref:`calling`. """ assert not self.is_historic(), ( "Cannot directly call a historic hook - use call_historic instead." ) self._verify_all_args_are_provided(kwargs) firstresult = self.spec.opts.get("firstresult", False) if self.spec else False # Copy because plugins may register other plugins during iteration (#438). > return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) firstresult = False kwargs = {'item': } self = /usr/lib/python3/dist-packages/pluggy/_hooks.py:512: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> hook_name = 'pytest_runtest_call' methods = [>] kwargs = {'item': } firstresult = False def _hookexec( self, hook_name: str, methods: Sequence[HookImpl], kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: # called from all hookcaller instances. # enable_tracing will set its own wrapping function at self._inner_hookexec > return self._inner_hookexec(hook_name, methods, kwargs, firstresult) firstresult = False hook_name = 'pytest_runtest_call' kwargs = {'item': } methods = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> /usr/lib/python3/dist-packages/pluggy/_manager.py:120: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: teardown.throw(exception) except RuntimeError as re: # StopIteration from generator causes RuntimeError # even for coroutine usage - see #544 if ( isinstance(exception, StopIteration) and re.__cause__ is exception ): teardown.close() continue else: raise else: teardown.send(result) # Following is unreachable for a well behaved hook wrapper. # Try to force finalizers otherwise postponed till GC action. # Note: close() may raise if generator handles GeneratorExit. teardown.close() except StopIteration as si: result = si.value exception = None continue except BaseException as e: exception = e continue _raise_wrapfail(teardown, "has second yield") if exception is not None: > raise exception __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:167: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from thread_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/threadexception.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def thread_exception_runtest_hook() -> Generator[None]: with catch_threading_exception() as cm: try: > yield cm = <_pytest.threadexception.catch_threading_exception object at 0xffff7d11ec10> /usr/lib/python3/dist-packages/_pytest/threadexception.py:68: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from unraisable_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:95: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def unraisable_exception_runtest_hook() -> Generator[None]: with catch_unraisable_exception() as cm: try: > yield cm = <_pytest.unraisableexception.catch_unraisable_exception object at 0xffff78ac44b0> /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:70: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: nodes.Item) -> Generator[None]: self.log_cli_handler.set_when("call") > yield from self._runtest_for(item, "call") item = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> /usr/lib/python3/dist-packages/_pytest/logging.py:846: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = when = 'call' def _runtest_for(self, item: nodes.Item, when: str) -> Generator[None]: """Implement the internals of the pytest_runtest_xxx() hooks.""" with catching_logs( self.caplog_handler, level=self.log_level, ) as caplog_handler, catching_logs( self.report_handler, level=self.log_level, ) as report_handler: caplog_handler.reset() report_handler.reset() item.stash[caplog_records_key][when] = caplog_handler.records item.stash[caplog_handler_key] = caplog_handler try: > yield caplog_handler = item = log = '' report_handler = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> when = 'call' /usr/lib/python3/dist-packages/_pytest/logging.py:829: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = > _state='suspended' _in_suspended=False> _capture_fixture=None> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: Item) -> Generator[None]: with self.item_capture("call", item): > return (yield) item = self = > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None> /usr/lib/python3/dist-packages/_pytest/capture.py:898: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = @hookimpl(wrapper=True) def pytest_runtest_call(item: Item) -> Generator[None]: xfailed = item.stash.get(xfailed_key, None) if xfailed is None: item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) if xfailed and not item.config.option.runxfail and not xfailed.run: xfail("[NOTRUN] " + xfailed.reason) try: > return (yield) item = xfailed = None /usr/lib/python3/dist-packages/_pytest/skipping.py:257: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: > res = hook_impl.function(*args) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:121: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = def pytest_runtest_call(item: Item) -> None: _update_current_test_var(item, "call") try: del sys.last_type del sys.last_value del sys.last_traceback if sys.version_info >= (3, 12, 0): del sys.last_exc # type:ignore[attr-defined] except AttributeError: pass try: > item.runtest() item = /usr/lib/python3/dist-packages/_pytest/runner.py:174: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def runtest(self) -> None: > returncode, actual_messages = self.parent.run_mypy(self.mypy_item) self = pytest_mypy_testing/plugin.py:64: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = item = MypyTestItem(name='mypy_test_invalid_assignment_only_error_code', lineno=27, end_lineno=30, expected_messages=[Message..._code='assignment')], func_node=, marks={'mypy_testing'}, actual_messages=[]) def run_mypy(self, item: MypyTestItem) -> Tuple[int, List[Message]]: if self._mypy_result is None: > self._mypy_result = self._run_mypy(self.path) item = MypyTestItem(name='mypy_test_invalid_assignment_only_error_code', lineno=27, end_lineno=30, expected_messages=[Message(filename='/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing', lineno=30, colno=None, severity=Severity.ERROR, message='', revealed_type=None, error_code='assignment')], func_node=, marks={'mypy_testing'}, actual_messages=[]) self = pytest_mypy_testing/plugin.py:136: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') def _run_mypy(self, filename: Union[pathlib.Path, os.PathLike, str]) -> MypyResult: filename = pathlib.Path(filename) with tempfile.TemporaryDirectory(prefix="pytest-mypy-testing-") as tmp_dir_name: mypy_cache_dir = os.path.join(tmp_dir_name, "mypy_cache") os.makedirs(mypy_cache_dir) mypy_args = [ "--cache-dir={}".format(mypy_cache_dir), "--check-untyped-defs", "--hide-error-context", "--no-color-output", "--no-error-summary", "--no-pretty", "--soft-error-limit=-1", "--no-silence-site-packages", "--no-warn-unused-configs", "--show-column-numbers", "--show-error-codes", "--show-traceback", str(filename), ] out, err, returncode = mypy.api.run(mypy_args) lines = (out + err).splitlines() file_messages = [ msg > for msg in map(Message.from_output, lines) if (msg.filename == self.mypy_file.filename) and not ( msg.severity is Severity.NOTE and msg.message == "See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports" ) ] err = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)\n') filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') lines = ['tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:49:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:50:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"', 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"', 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:80:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:81:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:87:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"', '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)'] mypy_args = ['--cache-dir=/tmp/pytest-mypy-testing-i5g1lcw5/mypy_cache', '--check-untyped-defs', '--hide-error-context', '--no-color-output', '--no-error-summary', '--no-pretty', '--soft-error-limit=-1', '--no-silence-site-packages', '--no-warn-unused-configs', '--show-column-numbers', '--show-error-codes', '--show-traceback', '/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing'] mypy_cache_dir = '/tmp/pytest-mypy-testing-i5g1lcw5/mypy_cache' out = ('tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:49:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:50:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"\n' 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"\n' 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:80:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:81:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:87:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"\n') returncode = 1 self = tmp_dir_name = '/tmp/pytest-mypy-testing-i5g1lcw5' pytest_mypy_testing/plugin.py:173: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ cls = line = '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must be 3.9 or higher)' @classmethod def from_output(cls, line: str) -> "Message": """Create message object from mypy output line. >>> m = Message.from_output("z.py:1: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1:13: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1: note: Revealed type is 'bar'") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, "Revealed type is 'bar'", 'bar', None) >>> m = Message.from_output('z.py:1: note: Revealed type is "bar"') >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'Revealed type is "bar"', 'bar', None) >>> m = Message.from_output("z.py:1:13: error: bar [baz]") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.ERROR, 'bar', None, 'baz') """ m = cls.OUTPUT_RE.match(line) if not m: > raise ValueError("Not a valid mypy message") E ValueError: Not a valid mypy message cls = line = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)') m = None pytest_mypy_testing/message.py:295: ValueError _______________________ [mypy]mypy_test_use_reveal_type ________________________ cls = func = . at 0xffff6efc6480> when = 'call' reraise = (, ) @classmethod def from_call( cls, func: Callable[[], TResult], when: Literal["collect", "setup", "call", "teardown"], reraise: type[BaseException] | tuple[type[BaseException], ...] | None = None, ) -> CallInfo[TResult]: """Call func, wrapping the result in a CallInfo. :param func: The function to call. Called without arguments. :type func: Callable[[], _pytest.runner.TResult] :param when: The phase in which the function is called. :param reraise: Exception or exceptions that shall propagate if raised by the function, instead of being wrapped in the CallInfo. """ excinfo = None start = timing.time() precise_start = timing.perf_counter() try: > result: TResult | None = func() cls = duration = 14.227428380982019 excinfo = func = . at 0xffff6efc6480> precise_start = 696383.945078619 precise_stop = 696398.172507 reraise = (, ) result = None start = 1756411042.4535818 stop = 1756411056.6810117 when = 'call' /usr/lib/python3/dist-packages/_pytest/runner.py:341: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise ) item = kwds = {} runtest_hook = /usr/lib/python3/dist-packages/_pytest/runner.py:242: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = kwargs = {'item': } firstresult = False def __call__(self, **kwargs: object) -> Any: """Call the hook. Only accepts keyword arguments, which should match the hook specification. Returns the result(s) of calling all registered plugins, see :ref:`calling`. """ assert not self.is_historic(), ( "Cannot directly call a historic hook - use call_historic instead." ) self._verify_all_args_are_provided(kwargs) firstresult = self.spec.opts.get("firstresult", False) if self.spec else False # Copy because plugins may register other plugins during iteration (#438). > return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) firstresult = False kwargs = {'item': } self = /usr/lib/python3/dist-packages/pluggy/_hooks.py:512: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> hook_name = 'pytest_runtest_call' methods = [>] kwargs = {'item': } firstresult = False def _hookexec( self, hook_name: str, methods: Sequence[HookImpl], kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: # called from all hookcaller instances. # enable_tracing will set its own wrapping function at self._inner_hookexec > return self._inner_hookexec(hook_name, methods, kwargs, firstresult) firstresult = False hook_name = 'pytest_runtest_call' kwargs = {'item': } methods = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> /usr/lib/python3/dist-packages/pluggy/_manager.py:120: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: teardown.throw(exception) except RuntimeError as re: # StopIteration from generator causes RuntimeError # even for coroutine usage - see #544 if ( isinstance(exception, StopIteration) and re.__cause__ is exception ): teardown.close() continue else: raise else: teardown.send(result) # Following is unreachable for a well behaved hook wrapper. # Try to force finalizers otherwise postponed till GC action. # Note: close() may raise if generator handles GeneratorExit. teardown.close() except StopIteration as si: result = si.value exception = None continue except BaseException as e: exception = e continue _raise_wrapfail(teardown, "has second yield") if exception is not None: > raise exception __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:167: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from thread_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/threadexception.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def thread_exception_runtest_hook() -> Generator[None]: with catch_threading_exception() as cm: try: > yield cm = <_pytest.threadexception.catch_threading_exception object at 0xffff6fc74e50> /usr/lib/python3/dist-packages/_pytest/threadexception.py:68: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from unraisable_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:95: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def unraisable_exception_runtest_hook() -> Generator[None]: with catch_unraisable_exception() as cm: try: > yield cm = <_pytest.unraisableexception.catch_unraisable_exception object at 0xffff71ba94d0> /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:70: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: nodes.Item) -> Generator[None]: self.log_cli_handler.set_when("call") > yield from self._runtest_for(item, "call") item = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> /usr/lib/python3/dist-packages/_pytest/logging.py:846: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = , when = 'call' def _runtest_for(self, item: nodes.Item, when: str) -> Generator[None]: """Implement the internals of the pytest_runtest_xxx() hooks.""" with catching_logs( self.caplog_handler, level=self.log_level, ) as caplog_handler, catching_logs( self.report_handler, level=self.log_level, ) as report_handler: caplog_handler.reset() report_handler.reset() item.stash[caplog_records_key][when] = caplog_handler.records item.stash[caplog_handler_key] = caplog_handler try: > yield caplog_handler = item = log = '' report_handler = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> when = 'call' /usr/lib/python3/dist-packages/_pytest/logging.py:829: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = > _state='suspended' _in_suspended=False> _capture_fixture=None> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: Item) -> Generator[None]: with self.item_capture("call", item): > return (yield) item = self = > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None> /usr/lib/python3/dist-packages/_pytest/capture.py:898: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = @hookimpl(wrapper=True) def pytest_runtest_call(item: Item) -> Generator[None]: xfailed = item.stash.get(xfailed_key, None) if xfailed is None: item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) if xfailed and not item.config.option.runxfail and not xfailed.run: xfail("[NOTRUN] " + xfailed.reason) try: > return (yield) item = xfailed = None /usr/lib/python3/dist-packages/_pytest/skipping.py:257: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: > res = hook_impl.function(*args) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:121: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = def pytest_runtest_call(item: Item) -> None: _update_current_test_var(item, "call") try: del sys.last_type del sys.last_value del sys.last_traceback if sys.version_info >= (3, 12, 0): del sys.last_exc # type:ignore[attr-defined] except AttributeError: pass try: > item.runtest() item = /usr/lib/python3/dist-packages/_pytest/runner.py:174: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def runtest(self) -> None: > returncode, actual_messages = self.parent.run_mypy(self.mypy_item) self = pytest_mypy_testing/plugin.py:64: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = item = MypyTestItem(name='mypy_test_use_reveal_type', lineno=47, end_lineno=50, expected_messages=[Message(filename='/build/r...', error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) def run_mypy(self, item: MypyTestItem) -> Tuple[int, List[Message]]: if self._mypy_result is None: > self._mypy_result = self._run_mypy(self.path) item = MypyTestItem(name='mypy_test_use_reveal_type', lineno=47, end_lineno=50, expected_messages=[Message(filename='/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing', lineno=49, colno=None, severity=Severity.NOTE, message='Revealed type is ' "'Literal[123]?'", revealed_type='Literal[123]?', error_code=None), Message(filename='/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing', lineno=50, colno=None, severity=Severity.NOTE, message='Revealed type is ' "'Literal[456]?'", revealed_type='Literal[456]?', error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) self = pytest_mypy_testing/plugin.py:136: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') def _run_mypy(self, filename: Union[pathlib.Path, os.PathLike, str]) -> MypyResult: filename = pathlib.Path(filename) with tempfile.TemporaryDirectory(prefix="pytest-mypy-testing-") as tmp_dir_name: mypy_cache_dir = os.path.join(tmp_dir_name, "mypy_cache") os.makedirs(mypy_cache_dir) mypy_args = [ "--cache-dir={}".format(mypy_cache_dir), "--check-untyped-defs", "--hide-error-context", "--no-color-output", "--no-error-summary", "--no-pretty", "--soft-error-limit=-1", "--no-silence-site-packages", "--no-warn-unused-configs", "--show-column-numbers", "--show-error-codes", "--show-traceback", str(filename), ] out, err, returncode = mypy.api.run(mypy_args) lines = (out + err).splitlines() file_messages = [ msg > for msg in map(Message.from_output, lines) if (msg.filename == self.mypy_file.filename) and not ( msg.severity is Severity.NOTE and msg.message == "See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports" ) ] err = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)\n') filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') lines = ['tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:49:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:50:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"', 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"', 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:80:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:81:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:87:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"', '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)'] mypy_args = ['--cache-dir=/tmp/pytest-mypy-testing-u9obqhlc/mypy_cache', '--check-untyped-defs', '--hide-error-context', '--no-color-output', '--no-error-summary', '--no-pretty', '--soft-error-limit=-1', '--no-silence-site-packages', '--no-warn-unused-configs', '--show-column-numbers', '--show-error-codes', '--show-traceback', '/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing'] mypy_cache_dir = '/tmp/pytest-mypy-testing-u9obqhlc/mypy_cache' out = ('tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:49:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:50:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"\n' 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"\n' 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:80:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:81:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:87:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"\n') returncode = 1 self = tmp_dir_name = '/tmp/pytest-mypy-testing-u9obqhlc' pytest_mypy_testing/plugin.py:173: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ cls = line = '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must be 3.9 or higher)' @classmethod def from_output(cls, line: str) -> "Message": """Create message object from mypy output line. >>> m = Message.from_output("z.py:1: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1:13: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1: note: Revealed type is 'bar'") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, "Revealed type is 'bar'", 'bar', None) >>> m = Message.from_output('z.py:1: note: Revealed type is "bar"') >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'Revealed type is "bar"', 'bar', None) >>> m = Message.from_output("z.py:1:13: error: bar [baz]") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.ERROR, 'bar', None, 'baz') """ m = cls.OUTPUT_RE.match(line) if not m: > raise ValueError("Not a valid mypy message") E ValueError: Not a valid mypy message cls = line = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)') m = None pytest_mypy_testing/message.py:295: ValueError __________________ [mypy]mypy_test_use_reveal_type__float_var __________________ cls = func = . at 0xffff6de7dbc0> when = 'call' reraise = (, ) @classmethod def from_call( cls, func: Callable[[], TResult], when: Literal["collect", "setup", "call", "teardown"], reraise: type[BaseException] | tuple[type[BaseException], ...] | None = None, ) -> CallInfo[TResult]: """Call func, wrapping the result in a CallInfo. :param func: The function to call. Called without arguments. :type func: Callable[[], _pytest.runner.TResult] :param when: The phase in which the function is called. :param reraise: Exception or exceptions that shall propagate if raised by the function, instead of being wrapped in the CallInfo. """ excinfo = None start = timing.time() precise_start = timing.perf_counter() try: > result: TResult | None = func() cls = duration = 12.771961299935356 excinfo = func = . at 0xffff6de7dbc0> precise_start = 696398.355324496 precise_stop = 696411.127285796 reraise = (, ) result = None start = 1756411056.8638277 stop = 1756411069.6357903 when = 'call' /usr/lib/python3/dist-packages/_pytest/runner.py:341: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise ) item = kwds = {} runtest_hook = /usr/lib/python3/dist-packages/_pytest/runner.py:242: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = kwargs = {'item': } firstresult = False def __call__(self, **kwargs: object) -> Any: """Call the hook. Only accepts keyword arguments, which should match the hook specification. Returns the result(s) of calling all registered plugins, see :ref:`calling`. """ assert not self.is_historic(), ( "Cannot directly call a historic hook - use call_historic instead." ) self._verify_all_args_are_provided(kwargs) firstresult = self.spec.opts.get("firstresult", False) if self.spec else False # Copy because plugins may register other plugins during iteration (#438). > return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) firstresult = False kwargs = {'item': } self = /usr/lib/python3/dist-packages/pluggy/_hooks.py:512: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> hook_name = 'pytest_runtest_call' methods = [>] kwargs = {'item': } firstresult = False def _hookexec( self, hook_name: str, methods: Sequence[HookImpl], kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: # called from all hookcaller instances. # enable_tracing will set its own wrapping function at self._inner_hookexec > return self._inner_hookexec(hook_name, methods, kwargs, firstresult) firstresult = False hook_name = 'pytest_runtest_call' kwargs = {'item': } methods = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> /usr/lib/python3/dist-packages/pluggy/_manager.py:120: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: teardown.throw(exception) except RuntimeError as re: # StopIteration from generator causes RuntimeError # even for coroutine usage - see #544 if ( isinstance(exception, StopIteration) and re.__cause__ is exception ): teardown.close() continue else: raise else: teardown.send(result) # Following is unreachable for a well behaved hook wrapper. # Try to force finalizers otherwise postponed till GC action. # Note: close() may raise if generator handles GeneratorExit. teardown.close() except StopIteration as si: result = si.value exception = None continue except BaseException as e: exception = e continue _raise_wrapfail(teardown, "has second yield") if exception is not None: > raise exception __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:167: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from thread_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/threadexception.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def thread_exception_runtest_hook() -> Generator[None]: with catch_threading_exception() as cm: try: > yield cm = <_pytest.threadexception.catch_threading_exception object at 0xffff8092b5b0> /usr/lib/python3/dist-packages/_pytest/threadexception.py:68: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from unraisable_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:95: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def unraisable_exception_runtest_hook() -> Generator[None]: with catch_unraisable_exception() as cm: try: > yield cm = <_pytest.unraisableexception.catch_unraisable_exception object at 0xffff82ef4bb0> /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:70: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: nodes.Item) -> Generator[None]: self.log_cli_handler.set_when("call") > yield from self._runtest_for(item, "call") item = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> /usr/lib/python3/dist-packages/_pytest/logging.py:846: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = when = 'call' def _runtest_for(self, item: nodes.Item, when: str) -> Generator[None]: """Implement the internals of the pytest_runtest_xxx() hooks.""" with catching_logs( self.caplog_handler, level=self.log_level, ) as caplog_handler, catching_logs( self.report_handler, level=self.log_level, ) as report_handler: caplog_handler.reset() report_handler.reset() item.stash[caplog_records_key][when] = caplog_handler.records item.stash[caplog_handler_key] = caplog_handler try: > yield caplog_handler = item = log = '' report_handler = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> when = 'call' /usr/lib/python3/dist-packages/_pytest/logging.py:829: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = > _state='suspended' _in_suspended=False> _capture_fixture=None> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: Item) -> Generator[None]: with self.item_capture("call", item): > return (yield) item = self = > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None> /usr/lib/python3/dist-packages/_pytest/capture.py:898: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = @hookimpl(wrapper=True) def pytest_runtest_call(item: Item) -> Generator[None]: xfailed = item.stash.get(xfailed_key, None) if xfailed is None: item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) if xfailed and not item.config.option.runxfail and not xfailed.run: xfail("[NOTRUN] " + xfailed.reason) try: > return (yield) item = xfailed = None /usr/lib/python3/dist-packages/_pytest/skipping.py:257: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: > res = hook_impl.function(*args) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:121: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = def pytest_runtest_call(item: Item) -> None: _update_current_test_var(item, "call") try: del sys.last_type del sys.last_value del sys.last_traceback if sys.version_info >= (3, 12, 0): del sys.last_exc # type:ignore[attr-defined] except AttributeError: pass try: > item.runtest() item = /usr/lib/python3/dist-packages/_pytest/runner.py:174: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def runtest(self) -> None: > returncode, actual_messages = self.parent.run_mypy(self.mypy_item) self = pytest_mypy_testing/plugin.py:64: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = item = MypyTestItem(name='mypy_test_use_reveal_type__float_var', lineno=53, end_lineno=56, expected_messages=[Message(filenam...', error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) def run_mypy(self, item: MypyTestItem) -> Tuple[int, List[Message]]: if self._mypy_result is None: > self._mypy_result = self._run_mypy(self.path) item = MypyTestItem(name='mypy_test_use_reveal_type__float_var', lineno=53, end_lineno=56, expected_messages=[Message(filename='/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing', lineno=56, colno=None, severity=Severity.NOTE, message='Revealed type is ' "'builtins.float'", revealed_type='builtins.float', error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) self = pytest_mypy_testing/plugin.py:136: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') def _run_mypy(self, filename: Union[pathlib.Path, os.PathLike, str]) -> MypyResult: filename = pathlib.Path(filename) with tempfile.TemporaryDirectory(prefix="pytest-mypy-testing-") as tmp_dir_name: mypy_cache_dir = os.path.join(tmp_dir_name, "mypy_cache") os.makedirs(mypy_cache_dir) mypy_args = [ "--cache-dir={}".format(mypy_cache_dir), "--check-untyped-defs", "--hide-error-context", "--no-color-output", "--no-error-summary", "--no-pretty", "--soft-error-limit=-1", "--no-silence-site-packages", "--no-warn-unused-configs", "--show-column-numbers", "--show-error-codes", "--show-traceback", str(filename), ] out, err, returncode = mypy.api.run(mypy_args) lines = (out + err).splitlines() file_messages = [ msg > for msg in map(Message.from_output, lines) if (msg.filename == self.mypy_file.filename) and not ( msg.severity is Severity.NOTE and msg.message == "See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports" ) ] err = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)\n') filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') lines = ['tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:49:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:50:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"', 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"', 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:80:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:81:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:87:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"', '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)'] mypy_args = ['--cache-dir=/tmp/pytest-mypy-testing-vcoi_vyt/mypy_cache', '--check-untyped-defs', '--hide-error-context', '--no-color-output', '--no-error-summary', '--no-pretty', '--soft-error-limit=-1', '--no-silence-site-packages', '--no-warn-unused-configs', '--show-column-numbers', '--show-error-codes', '--show-traceback', '/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing'] mypy_cache_dir = '/tmp/pytest-mypy-testing-vcoi_vyt/mypy_cache' out = ('tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:49:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:50:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"\n' 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"\n' 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:80:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:81:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:87:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"\n') returncode = 1 self = tmp_dir_name = '/tmp/pytest-mypy-testing-vcoi_vyt' pytest_mypy_testing/plugin.py:173: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ cls = line = '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must be 3.9 or higher)' @classmethod def from_output(cls, line: str) -> "Message": """Create message object from mypy output line. >>> m = Message.from_output("z.py:1: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1:13: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1: note: Revealed type is 'bar'") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, "Revealed type is 'bar'", 'bar', None) >>> m = Message.from_output('z.py:1: note: Revealed type is "bar"') >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'Revealed type is "bar"', 'bar', None) >>> m = Message.from_output("z.py:1:13: error: bar [baz]") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.ERROR, 'bar', None, 'baz') """ m = cls.OUTPUT_RE.match(line) if not m: > raise ValueError("Not a valid mypy message") E ValueError: Not a valid mypy message cls = line = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)') m = None pytest_mypy_testing/message.py:295: ValueError ___________________ [mypy]mypy_test_use_reveal_type__int_var ___________________ cls = func = . at 0xffff6eba9120> when = 'call' reraise = (, ) @classmethod def from_call( cls, func: Callable[[], TResult], when: Literal["collect", "setup", "call", "teardown"], reraise: type[BaseException] | tuple[type[BaseException], ...] | None = None, ) -> CallInfo[TResult]: """Call func, wrapping the result in a CallInfo. :param func: The function to call. Called without arguments. :type func: Callable[[], _pytest.runner.TResult] :param when: The phase in which the function is called. :param reraise: Exception or exceptions that shall propagate if raised by the function, instead of being wrapped in the CallInfo. """ excinfo = None start = timing.time() precise_start = timing.perf_counter() try: > result: TResult | None = func() cls = duration = 20.769273161073215 excinfo = func = . at 0xffff6eba9120> precise_start = 696411.340405413 precise_stop = 696432.109678574 reraise = (, ) result = None start = 1756411069.8489087 stop = 1756411090.6181831 when = 'call' /usr/lib/python3/dist-packages/_pytest/runner.py:341: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise ) item = kwds = {} runtest_hook = /usr/lib/python3/dist-packages/_pytest/runner.py:242: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = kwargs = {'item': } firstresult = False def __call__(self, **kwargs: object) -> Any: """Call the hook. Only accepts keyword arguments, which should match the hook specification. Returns the result(s) of calling all registered plugins, see :ref:`calling`. """ assert not self.is_historic(), ( "Cannot directly call a historic hook - use call_historic instead." ) self._verify_all_args_are_provided(kwargs) firstresult = self.spec.opts.get("firstresult", False) if self.spec else False # Copy because plugins may register other plugins during iteration (#438). > return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) firstresult = False kwargs = {'item': } self = /usr/lib/python3/dist-packages/pluggy/_hooks.py:512: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> hook_name = 'pytest_runtest_call' methods = [>] kwargs = {'item': } firstresult = False def _hookexec( self, hook_name: str, methods: Sequence[HookImpl], kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: # called from all hookcaller instances. # enable_tracing will set its own wrapping function at self._inner_hookexec > return self._inner_hookexec(hook_name, methods, kwargs, firstresult) firstresult = False hook_name = 'pytest_runtest_call' kwargs = {'item': } methods = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> /usr/lib/python3/dist-packages/pluggy/_manager.py:120: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: teardown.throw(exception) except RuntimeError as re: # StopIteration from generator causes RuntimeError # even for coroutine usage - see #544 if ( isinstance(exception, StopIteration) and re.__cause__ is exception ): teardown.close() continue else: raise else: teardown.send(result) # Following is unreachable for a well behaved hook wrapper. # Try to force finalizers otherwise postponed till GC action. # Note: close() may raise if generator handles GeneratorExit. teardown.close() except StopIteration as si: result = si.value exception = None continue except BaseException as e: exception = e continue _raise_wrapfail(teardown, "has second yield") if exception is not None: > raise exception __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:167: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from thread_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/threadexception.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def thread_exception_runtest_hook() -> Generator[None]: with catch_threading_exception() as cm: try: > yield cm = <_pytest.threadexception.catch_threading_exception object at 0xffff794fdeb0> /usr/lib/python3/dist-packages/_pytest/threadexception.py:68: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from unraisable_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:95: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def unraisable_exception_runtest_hook() -> Generator[None]: with catch_unraisable_exception() as cm: try: > yield cm = <_pytest.unraisableexception.catch_unraisable_exception object at 0xffff63ff1c10> /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:70: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: nodes.Item) -> Generator[None]: self.log_cli_handler.set_when("call") > yield from self._runtest_for(item, "call") item = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> /usr/lib/python3/dist-packages/_pytest/logging.py:846: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = when = 'call' def _runtest_for(self, item: nodes.Item, when: str) -> Generator[None]: """Implement the internals of the pytest_runtest_xxx() hooks.""" with catching_logs( self.caplog_handler, level=self.log_level, ) as caplog_handler, catching_logs( self.report_handler, level=self.log_level, ) as report_handler: caplog_handler.reset() report_handler.reset() item.stash[caplog_records_key][when] = caplog_handler.records item.stash[caplog_handler_key] = caplog_handler try: > yield caplog_handler = item = log = '' report_handler = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> when = 'call' /usr/lib/python3/dist-packages/_pytest/logging.py:829: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = > _state='suspended' _in_suspended=False> _capture_fixture=None> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: Item) -> Generator[None]: with self.item_capture("call", item): > return (yield) item = self = > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None> /usr/lib/python3/dist-packages/_pytest/capture.py:898: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = @hookimpl(wrapper=True) def pytest_runtest_call(item: Item) -> Generator[None]: xfailed = item.stash.get(xfailed_key, None) if xfailed is None: item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) if xfailed and not item.config.option.runxfail and not xfailed.run: xfail("[NOTRUN] " + xfailed.reason) try: > return (yield) item = xfailed = None /usr/lib/python3/dist-packages/_pytest/skipping.py:257: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: > res = hook_impl.function(*args) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:121: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = def pytest_runtest_call(item: Item) -> None: _update_current_test_var(item, "call") try: del sys.last_type del sys.last_value del sys.last_traceback if sys.version_info >= (3, 12, 0): del sys.last_exc # type:ignore[attr-defined] except AttributeError: pass try: > item.runtest() item = /usr/lib/python3/dist-packages/_pytest/runner.py:174: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def runtest(self) -> None: > returncode, actual_messages = self.parent.run_mypy(self.mypy_item) self = pytest_mypy_testing/plugin.py:64: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = item = MypyTestItem(name='mypy_test_use_reveal_type__int_var', lineno=59, end_lineno=62, expected_messages=[Message(filename=...', error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) def run_mypy(self, item: MypyTestItem) -> Tuple[int, List[Message]]: if self._mypy_result is None: > self._mypy_result = self._run_mypy(self.path) item = MypyTestItem(name='mypy_test_use_reveal_type__int_var', lineno=59, end_lineno=62, expected_messages=[Message(filename='/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing', lineno=62, colno=None, severity=Severity.NOTE, message='Revealed type is ' "'builtins.int'", revealed_type='builtins.int', error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) self = pytest_mypy_testing/plugin.py:136: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') def _run_mypy(self, filename: Union[pathlib.Path, os.PathLike, str]) -> MypyResult: filename = pathlib.Path(filename) with tempfile.TemporaryDirectory(prefix="pytest-mypy-testing-") as tmp_dir_name: mypy_cache_dir = os.path.join(tmp_dir_name, "mypy_cache") os.makedirs(mypy_cache_dir) mypy_args = [ "--cache-dir={}".format(mypy_cache_dir), "--check-untyped-defs", "--hide-error-context", "--no-color-output", "--no-error-summary", "--no-pretty", "--soft-error-limit=-1", "--no-silence-site-packages", "--no-warn-unused-configs", "--show-column-numbers", "--show-error-codes", "--show-traceback", str(filename), ] out, err, returncode = mypy.api.run(mypy_args) lines = (out + err).splitlines() file_messages = [ msg > for msg in map(Message.from_output, lines) if (msg.filename == self.mypy_file.filename) and not ( msg.severity is Severity.NOTE and msg.message == "See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports" ) ] err = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)\n') filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') lines = ['tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:49:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:50:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"', 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"', 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:80:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:81:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:87:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"', '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)'] mypy_args = ['--cache-dir=/tmp/pytest-mypy-testing-gttiy8qy/mypy_cache', '--check-untyped-defs', '--hide-error-context', '--no-color-output', '--no-error-summary', '--no-pretty', '--soft-error-limit=-1', '--no-silence-site-packages', '--no-warn-unused-configs', '--show-column-numbers', '--show-error-codes', '--show-traceback', '/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing'] mypy_cache_dir = '/tmp/pytest-mypy-testing-gttiy8qy/mypy_cache' out = ('tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:49:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:50:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"\n' 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"\n' 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:80:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:81:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:87:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"\n') returncode = 1 self = tmp_dir_name = '/tmp/pytest-mypy-testing-gttiy8qy' pytest_mypy_testing/plugin.py:173: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ cls = line = '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must be 3.9 or higher)' @classmethod def from_output(cls, line: str) -> "Message": """Create message object from mypy output line. >>> m = Message.from_output("z.py:1: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1:13: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1: note: Revealed type is 'bar'") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, "Revealed type is 'bar'", 'bar', None) >>> m = Message.from_output('z.py:1: note: Revealed type is "bar"') >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'Revealed type is "bar"', 'bar', None) >>> m = Message.from_output("z.py:1:13: error: bar [baz]") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.ERROR, 'bar', None, 'baz') """ m = cls.OUTPUT_RE.match(line) if not m: > raise ValueError("Not a valid mypy message") E ValueError: Not a valid mypy message cls = line = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)') m = None pytest_mypy_testing/message.py:295: ValueError ________________ [mypy]mypy_test_use_reveal_type__int_list_var _________________ cls = func = . at 0xffff6ddf4180> when = 'call' reraise = (, ) @classmethod def from_call( cls, func: Callable[[], TResult], when: Literal["collect", "setup", "call", "teardown"], reraise: type[BaseException] | tuple[type[BaseException], ...] | None = None, ) -> CallInfo[TResult]: """Call func, wrapping the result in a CallInfo. :param func: The function to call. Called without arguments. :type func: Callable[[], _pytest.runner.TResult] :param when: The phase in which the function is called. :param reraise: Exception or exceptions that shall propagate if raised by the function, instead of being wrapped in the CallInfo. """ excinfo = None start = timing.time() precise_start = timing.perf_counter() try: > result: TResult | None = func() cls = duration = 17.55449345789384 excinfo = func = . at 0xffff6ddf4180> precise_start = 696432.405043818 precise_stop = 696449.959537276 reraise = (, ) result = None start = 1756411090.913547 stop = 1756411108.4680417 when = 'call' /usr/lib/python3/dist-packages/_pytest/runner.py:341: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise ) item = kwds = {} runtest_hook = /usr/lib/python3/dist-packages/_pytest/runner.py:242: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = kwargs = {'item': } firstresult = False def __call__(self, **kwargs: object) -> Any: """Call the hook. Only accepts keyword arguments, which should match the hook specification. Returns the result(s) of calling all registered plugins, see :ref:`calling`. """ assert not self.is_historic(), ( "Cannot directly call a historic hook - use call_historic instead." ) self._verify_all_args_are_provided(kwargs) firstresult = self.spec.opts.get("firstresult", False) if self.spec else False # Copy because plugins may register other plugins during iteration (#438). > return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) firstresult = False kwargs = {'item': } self = /usr/lib/python3/dist-packages/pluggy/_hooks.py:512: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> hook_name = 'pytest_runtest_call' methods = [>] kwargs = {'item': } firstresult = False def _hookexec( self, hook_name: str, methods: Sequence[HookImpl], kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: # called from all hookcaller instances. # enable_tracing will set its own wrapping function at self._inner_hookexec > return self._inner_hookexec(hook_name, methods, kwargs, firstresult) firstresult = False hook_name = 'pytest_runtest_call' kwargs = {'item': } methods = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> /usr/lib/python3/dist-packages/pluggy/_manager.py:120: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: teardown.throw(exception) except RuntimeError as re: # StopIteration from generator causes RuntimeError # even for coroutine usage - see #544 if ( isinstance(exception, StopIteration) and re.__cause__ is exception ): teardown.close() continue else: raise else: teardown.send(result) # Following is unreachable for a well behaved hook wrapper. # Try to force finalizers otherwise postponed till GC action. # Note: close() may raise if generator handles GeneratorExit. teardown.close() except StopIteration as si: result = si.value exception = None continue except BaseException as e: exception = e continue _raise_wrapfail(teardown, "has second yield") if exception is not None: > raise exception __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:167: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from thread_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/threadexception.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def thread_exception_runtest_hook() -> Generator[None]: with catch_threading_exception() as cm: try: > yield cm = <_pytest.threadexception.catch_threading_exception object at 0xffff7a0cf890> /usr/lib/python3/dist-packages/_pytest/threadexception.py:68: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from unraisable_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:95: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def unraisable_exception_runtest_hook() -> Generator[None]: with catch_unraisable_exception() as cm: try: > yield cm = <_pytest.unraisableexception.catch_unraisable_exception object at 0xffff64adf350> /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:70: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: nodes.Item) -> Generator[None]: self.log_cli_handler.set_when("call") > yield from self._runtest_for(item, "call") item = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> /usr/lib/python3/dist-packages/_pytest/logging.py:846: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = when = 'call' def _runtest_for(self, item: nodes.Item, when: str) -> Generator[None]: """Implement the internals of the pytest_runtest_xxx() hooks.""" with catching_logs( self.caplog_handler, level=self.log_level, ) as caplog_handler, catching_logs( self.report_handler, level=self.log_level, ) as report_handler: caplog_handler.reset() report_handler.reset() item.stash[caplog_records_key][when] = caplog_handler.records item.stash[caplog_handler_key] = caplog_handler try: > yield caplog_handler = item = log = '' report_handler = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> when = 'call' /usr/lib/python3/dist-packages/_pytest/logging.py:829: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = > _state='suspended' _in_suspended=False> _capture_fixture=None> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: Item) -> Generator[None]: with self.item_capture("call", item): > return (yield) item = self = > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None> /usr/lib/python3/dist-packages/_pytest/capture.py:898: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = @hookimpl(wrapper=True) def pytest_runtest_call(item: Item) -> Generator[None]: xfailed = item.stash.get(xfailed_key, None) if xfailed is None: item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) if xfailed and not item.config.option.runxfail and not xfailed.run: xfail("[NOTRUN] " + xfailed.reason) try: > return (yield) item = xfailed = None /usr/lib/python3/dist-packages/_pytest/skipping.py:257: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: > res = hook_impl.function(*args) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:121: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = def pytest_runtest_call(item: Item) -> None: _update_current_test_var(item, "call") try: del sys.last_type del sys.last_value del sys.last_traceback if sys.version_info >= (3, 12, 0): del sys.last_exc # type:ignore[attr-defined] except AttributeError: pass try: > item.runtest() item = /usr/lib/python3/dist-packages/_pytest/runner.py:174: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def runtest(self) -> None: > returncode, actual_messages = self.parent.run_mypy(self.mypy_item) self = pytest_mypy_testing/plugin.py:64: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = item = MypyTestItem(name='mypy_test_use_reveal_type__int_list_var', lineno=65, end_lineno=68, expected_messages=[Message(file...', error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) def run_mypy(self, item: MypyTestItem) -> Tuple[int, List[Message]]: if self._mypy_result is None: > self._mypy_result = self._run_mypy(self.path) item = MypyTestItem(name='mypy_test_use_reveal_type__int_list_var', lineno=65, end_lineno=68, expected_messages=[Message(filename='/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing', lineno=68, colno=None, severity=Severity.NOTE, message='Revealed type is ' "'builtins.list[builtins.int]'", revealed_type='builtins.list[builtins.int]', error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) self = pytest_mypy_testing/plugin.py:136: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') def _run_mypy(self, filename: Union[pathlib.Path, os.PathLike, str]) -> MypyResult: filename = pathlib.Path(filename) with tempfile.TemporaryDirectory(prefix="pytest-mypy-testing-") as tmp_dir_name: mypy_cache_dir = os.path.join(tmp_dir_name, "mypy_cache") os.makedirs(mypy_cache_dir) mypy_args = [ "--cache-dir={}".format(mypy_cache_dir), "--check-untyped-defs", "--hide-error-context", "--no-color-output", "--no-error-summary", "--no-pretty", "--soft-error-limit=-1", "--no-silence-site-packages", "--no-warn-unused-configs", "--show-column-numbers", "--show-error-codes", "--show-traceback", str(filename), ] out, err, returncode = mypy.api.run(mypy_args) lines = (out + err).splitlines() file_messages = [ msg > for msg in map(Message.from_output, lines) if (msg.filename == self.mypy_file.filename) and not ( msg.severity is Severity.NOTE and msg.message == "See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports" ) ] err = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)\n') filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') lines = ['tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:49:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:50:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"', 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"', 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:80:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:81:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:87:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"', '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)'] mypy_args = ['--cache-dir=/tmp/pytest-mypy-testing-z714au03/mypy_cache', '--check-untyped-defs', '--hide-error-context', '--no-color-output', '--no-error-summary', '--no-pretty', '--soft-error-limit=-1', '--no-silence-site-packages', '--no-warn-unused-configs', '--show-column-numbers', '--show-error-codes', '--show-traceback', '/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing'] mypy_cache_dir = '/tmp/pytest-mypy-testing-z714au03/mypy_cache' out = ('tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:49:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:50:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"\n' 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"\n' 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:80:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:81:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:87:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"\n') returncode = 1 self = tmp_dir_name = '/tmp/pytest-mypy-testing-z714au03' pytest_mypy_testing/plugin.py:173: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ cls = line = '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must be 3.9 or higher)' @classmethod def from_output(cls, line: str) -> "Message": """Create message object from mypy output line. >>> m = Message.from_output("z.py:1: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1:13: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1: note: Revealed type is 'bar'") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, "Revealed type is 'bar'", 'bar', None) >>> m = Message.from_output('z.py:1: note: Revealed type is "bar"') >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'Revealed type is "bar"', 'bar', None) >>> m = Message.from_output("z.py:1:13: error: bar [baz]") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.ERROR, 'bar', None, 'baz') """ m = cls.OUTPUT_RE.match(line) if not m: > raise ValueError("Not a valid mypy message") E ValueError: Not a valid mypy message cls = line = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)') m = None pytest_mypy_testing/message.py:295: ValueError ____ [mypy]mypy_test_use_reveal_type__int_list_var__with__inferred_asterisk ____ cls = func = . at 0xffff6dcefec0> when = 'call' reraise = (, ) @classmethod def from_call( cls, func: Callable[[], TResult], when: Literal["collect", "setup", "call", "teardown"], reraise: type[BaseException] | tuple[type[BaseException], ...] | None = None, ) -> CallInfo[TResult]: """Call func, wrapping the result in a CallInfo. :param func: The function to call. Called without arguments. :type func: Callable[[], _pytest.runner.TResult] :param when: The phase in which the function is called. :param reraise: Exception or exceptions that shall propagate if raised by the function, instead of being wrapped in the CallInfo. """ excinfo = None start = timing.time() precise_start = timing.perf_counter() try: > result: TResult | None = func() cls = duration = 19.178262411034666 excinfo = func = . at 0xffff6dcefec0> precise_start = 696450.176046756 precise_stop = 696469.354309167 reraise = (, ) result = None start = 1756411108.6845498 stop = 1756411127.8628142 when = 'call' /usr/lib/python3/dist-packages/_pytest/runner.py:341: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ > lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise ) item = kwds = {} runtest_hook = /usr/lib/python3/dist-packages/_pytest/runner.py:242: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = kwargs = {'item': } firstresult = False def __call__(self, **kwargs: object) -> Any: """Call the hook. Only accepts keyword arguments, which should match the hook specification. Returns the result(s) of calling all registered plugins, see :ref:`calling`. """ assert not self.is_historic(), ( "Cannot directly call a historic hook - use call_historic instead." ) self._verify_all_args_are_provided(kwargs) firstresult = self.spec.opts.get("firstresult", False) if self.spec else False # Copy because plugins may register other plugins during iteration (#438). > return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) firstresult = False kwargs = {'item': } self = /usr/lib/python3/dist-packages/pluggy/_hooks.py:512: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> hook_name = 'pytest_runtest_call' methods = [>] kwargs = {'item': } firstresult = False def _hookexec( self, hook_name: str, methods: Sequence[HookImpl], kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: # called from all hookcaller instances. # enable_tracing will set its own wrapping function at self._inner_hookexec > return self._inner_hookexec(hook_name, methods, kwargs, firstresult) firstresult = False hook_name = 'pytest_runtest_call' kwargs = {'item': } methods = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] self = <_pytest.config.PytestPluginManager object at 0xffff8953f230> /usr/lib/python3/dist-packages/pluggy/_manager.py:120: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: teardown.throw(exception) except RuntimeError as re: # StopIteration from generator causes RuntimeError # even for coroutine usage - see #544 if ( isinstance(exception, StopIteration) and re.__cause__ is exception ): teardown.close() continue else: raise else: teardown.send(result) # Following is unreachable for a well behaved hook wrapper. # Try to force finalizers otherwise postponed till GC action. # Note: close() may raise if generator handles GeneratorExit. teardown.close() except StopIteration as si: result = si.value exception = None continue except BaseException as e: exception = e continue _raise_wrapfail(teardown, "has second yield") if exception is not None: > raise exception __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:167: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from thread_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/threadexception.py:92: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def thread_exception_runtest_hook() -> Generator[None]: with catch_threading_exception() as cm: try: > yield cm = <_pytest.threadexception.catch_threading_exception object at 0xffff619d4770> /usr/lib/python3/dist-packages/_pytest/threadexception.py:68: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ @pytest.hookimpl(wrapper=True, tryfirst=True) def pytest_runtest_call() -> Generator[None]: > yield from unraisable_exception_runtest_hook() /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:95: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def unraisable_exception_runtest_hook() -> Generator[None]: with catch_unraisable_exception() as cm: try: > yield cm = <_pytest.unraisableexception.catch_unraisable_exception object at 0xffff64cdcbf0> /usr/lib/python3/dist-packages/_pytest/unraisableexception.py:70: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: nodes.Item) -> Generator[None]: self.log_cli_handler.set_when("call") > yield from self._runtest_for(item, "call") item = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> /usr/lib/python3/dist-packages/_pytest/logging.py:846: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> item = when = 'call' def _runtest_for(self, item: nodes.Item, when: str) -> Generator[None]: """Implement the internals of the pytest_runtest_xxx() hooks.""" with catching_logs( self.caplog_handler, level=self.log_level, ) as caplog_handler, catching_logs( self.report_handler, level=self.log_level, ) as report_handler: caplog_handler.reset() report_handler.reset() item.stash[caplog_records_key][when] = caplog_handler.records item.stash[caplog_handler_key] = caplog_handler try: > yield caplog_handler = item = log = '' report_handler = self = <_pytest.logging.LoggingPlugin object at 0xffff892db0e0> when = 'call' /usr/lib/python3/dist-packages/_pytest/logging.py:829: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = > _state='suspended' _in_suspended=False> _capture_fixture=None> item = @hookimpl(wrapper=True) def pytest_runtest_call(self, item: Item) -> Generator[None]: with self.item_capture("call", item): > return (yield) item = self = > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None> /usr/lib/python3/dist-packages/_pytest/capture.py:898: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: res = hook_impl.function(*args) if res is not None: results.append(res) if firstresult: # halt further impl calls break except BaseException as exc: exception = exc finally: if firstresult: # first result hooks return a single value result = results[0] if results else None else: result = results # run all wrapper post-yield blocks for teardown in reversed(teardowns): try: if exception is not None: try: > teardown.throw(exception) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:139: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = @hookimpl(wrapper=True) def pytest_runtest_call(item: Item) -> Generator[None]: xfailed = item.stash.get(xfailed_key, None) if xfailed is None: item.stash[xfailed_key] = xfailed = evaluate_xfail_marks(item) if xfailed and not item.config.option.runxfail and not xfailed.run: xfail("[NOTRUN] " + xfailed.reason) try: > return (yield) item = xfailed = None /usr/lib/python3/dist-packages/_pytest/skipping.py:257: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ hook_name = 'pytest_runtest_call' hook_impls = [>] caller_kwargs = {'item': } firstresult = False def _multicall( hook_name: str, hook_impls: Sequence[HookImpl], caller_kwargs: Mapping[str, object], firstresult: bool, ) -> object | list[object]: """Execute a call into multiple python functions/methods and return the result(s). ``caller_kwargs`` comes from HookCaller.__call__(). """ __tracebackhide__ = True results: list[object] = [] exception = None try: # run impl and wrapper setup functions in a loop teardowns: list[Teardown] = [] try: for hook_impl in reversed(hook_impls): try: args = [caller_kwargs[argname] for argname in hook_impl.argnames] except KeyError as e: # coverage bug - this is tested for argname in hook_impl.argnames: # pragma: no cover if argname not in caller_kwargs: raise HookCallError( f"hook call must provide argument {argname!r}" ) from e if hook_impl.hookwrapper: function_gen = run_old_style_hookwrapper(hook_impl, hook_name, args) next(function_gen) # first yield teardowns.append(function_gen) elif hook_impl.wrapper: try: # If this cast is not valid, a type error is raised below, # which is the desired response. res = hook_impl.function(*args) function_gen = cast(Generator[None, object, object], res) next(function_gen) # first yield teardowns.append(function_gen) except StopIteration: _raise_wrapfail(function_gen, "did not yield") else: > res = hook_impl.function(*args) __tracebackhide__ = True args = [] caller_kwargs = {'item': } exception = ValueError('Not a valid mypy message') firstresult = False function_gen = hook_impl = > hook_impls = [>, >, > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None>>, >, >, >] hook_name = 'pytest_runtest_call' res = result = [] results = [] teardown = teardowns = [, , , , ] /usr/lib/python3/dist-packages/pluggy/_callers.py:121: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ item = def pytest_runtest_call(item: Item) -> None: _update_current_test_var(item, "call") try: del sys.last_type del sys.last_value del sys.last_traceback if sys.version_info >= (3, 12, 0): del sys.last_exc # type:ignore[attr-defined] except AttributeError: pass try: > item.runtest() item = /usr/lib/python3/dist-packages/_pytest/runner.py:174: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def runtest(self) -> None: > returncode, actual_messages = self.parent.run_mypy(self.mypy_item) self = pytest_mypy_testing/plugin.py:64: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = item = MypyTestItem(name='mypy_test_use_reveal_type__int_list_var__with__inferred_asterisk', lineno=71, end_lineno=74, expect...', error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) def run_mypy(self, item: MypyTestItem) -> Tuple[int, List[Message]]: if self._mypy_result is None: > self._mypy_result = self._run_mypy(self.path) item = MypyTestItem(name='mypy_test_use_reveal_type__int_list_var__with__inferred_asterisk', lineno=71, end_lineno=74, expected_messages=[Message(filename='/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing', lineno=74, colno=None, severity=Severity.NOTE, message='Revealed type is ' "'builtins.list[builtins.int*]'", revealed_type='builtins.list[builtins.int]', error_code=None)], func_node=, marks={'mypy_testing'}, actual_messages=[]) self = pytest_mypy_testing/plugin.py:136: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') def _run_mypy(self, filename: Union[pathlib.Path, os.PathLike, str]) -> MypyResult: filename = pathlib.Path(filename) with tempfile.TemporaryDirectory(prefix="pytest-mypy-testing-") as tmp_dir_name: mypy_cache_dir = os.path.join(tmp_dir_name, "mypy_cache") os.makedirs(mypy_cache_dir) mypy_args = [ "--cache-dir={}".format(mypy_cache_dir), "--check-untyped-defs", "--hide-error-context", "--no-color-output", "--no-error-summary", "--no-pretty", "--soft-error-limit=-1", "--no-silence-site-packages", "--no-warn-unused-configs", "--show-column-numbers", "--show-error-codes", "--show-traceback", str(filename), ] out, err, returncode = mypy.api.run(mypy_args) lines = (out + err).splitlines() file_messages = [ msg > for msg in map(Message.from_output, lines) if (msg.filename == self.mypy_file.filename) and not ( msg.severity is Severity.NOTE and msg.message == "See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports" ) ] err = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)\n') filename = PosixPath('/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing') lines = ['tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]', 'tests/test_basics.mypy-testing:49:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:50:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"', 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"', 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"', 'tests/test_basics.mypy-testing:80:17: note: Revealed type is "Literal[123]?"', 'tests/test_basics.mypy-testing:81:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:87:17: note: Revealed type is "Literal[456]?"', 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"', '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)'] mypy_args = ['--cache-dir=/tmp/pytest-mypy-testing-uj_kbdfe/mypy_cache', '--check-untyped-defs', '--hide-error-context', '--no-color-output', '--no-error-summary', '--no-pretty', '--soft-error-limit=-1', '--no-silence-site-packages', '--no-warn-unused-configs', '--show-column-numbers', '--show-error-codes', '--show-traceback', '/build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/build/tests/test_basics.mypy-testing'] mypy_cache_dir = '/tmp/pytest-mypy-testing-uj_kbdfe/mypy_cache' out = ('tests/test_basics.mypy-testing:11:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:17:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:24:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:30:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:37:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:44:11: error: Incompatible types in ' 'assignment (expression has type "int", variable has type "str") ' '[assignment]\n' 'tests/test_basics.mypy-testing:49:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:50:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:56:17: note: Revealed type is ' '"builtins.float"\n' 'tests/test_basics.mypy-testing:62:17: note: Revealed type is "builtins.int"\n' 'tests/test_basics.mypy-testing:68:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:74:17: note: Revealed type is ' '"builtins.list[builtins.int]"\n' 'tests/test_basics.mypy-testing:80:17: note: Revealed type is ' '"Literal[123]?"\n' 'tests/test_basics.mypy-testing:81:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:87:17: note: Revealed type is ' '"Literal[456]?"\n' 'tests/test_basics.mypy-testing:99:17: note: Revealed type is ' '"builtins.list[Never]"\n') returncode = 1 self = tmp_dir_name = '/tmp/pytest-mypy-testing-uj_kbdfe' pytest_mypy_testing/plugin.py:173: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ cls = line = '../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must be 3.9 or higher)' @classmethod def from_output(cls, line: str) -> "Message": """Create message object from mypy output line. >>> m = Message.from_output("z.py:1: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1:13: note: bar") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.NOTE, 'bar', None, None) >>> m = Message.from_output("z.py:1: note: Revealed type is 'bar'") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, "Revealed type is 'bar'", 'bar', None) >>> m = Message.from_output('z.py:1: note: Revealed type is "bar"') >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, None, Severity.NOTE, 'Revealed type is "bar"', 'bar', None) >>> m = Message.from_output("z.py:1:13: error: bar [baz]") >>> (m.lineno, m.colno, m.severity, m.message, m.revealed_type, m.error_code) (1, 13, Severity.ERROR, 'bar', None, 'baz') """ m = cls.OUTPUT_RE.match(line) if not m: > raise ValueError("Not a valid mypy message") E ValueError: Not a valid mypy message cls = line = ('../../../mypy.ini: [mypy]: python_version: Python 3.8 is not supported (must ' 'be 3.9 or higher)') m = None pytest_mypy_testing/message.py:295: ValueError ============================= slowest 20 durations ============================= 35.25s call tests/test_basics.mypy-testing::[mypy]mypy_test_xfail_missing_note 31.18s call tests/test_basics.mypy-testing::[mypy]mypy_test_xfail_wrong_reveal_type 28.45s call tests/test_file_with_nonitem_messages.mypy-testing::[mypy]mypy_test_xfail_unexpected_note 25.16s call tests/test_basics.mypy-testing::[mypy]mypy_test_xfail_unexpected_note 20.77s call tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__int_var 19.18s call tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__int_list_var__with__inferred_asterisk 17.55s call tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__int_list_var 15.93s call tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_only_error_code 14.23s call tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type 14.23s call tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_no_message_and_no_error_code 12.77s call tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__float_var 12.67s call tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_with_error_code__message_does_not_match 12.02s call tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_only_error_code__error_code_does_not_match 11.83s call tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment 11.62s call tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_with_error_code 0.01s setup tests/test_parser.py::test_parse_file_basic_call_works_with_py37 0.00s call tests/test_parser.py::test_parse_file_basic_call_works_with_py37 0.00s call tests/test_plugin.py::test_pytest_collect_file[test_z.py] 0.00s call tests/test_plugin.py::test_pytest_collect_file[test_z.mypy-testing] 0.00s call tests/test_plugin.py::test_pytest_collect_file_not_test_file_name[z.py] =========================== short test summary info ============================ FAILED tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment - ValueError: Not a valid mypy message FAILED tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_with_error_code - ValueError: Not a valid mypy message FAILED tests/test_basics.mypy-testing::[mypy]mypy_test_invalid_assignment_only_error_code - ValueError: Not a valid mypy message FAILED tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type - ValueError: Not a valid mypy message FAILED tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__float_var - ValueError: Not a valid mypy message FAILED tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__int_var - ValueError: Not a valid mypy message FAILED tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__int_list_var - ValueError: Not a valid mypy message FAILED tests/test_basics.mypy-testing::[mypy]mypy_test_use_reveal_type__int_list_var__with__inferred_asterisk - ValueError: Not a valid mypy message ======== 8 failed, 53 passed, 1 skipped, 7 xfailed in 287.91s (0:04:47) ======== E: pybuild pybuild:389: test: plugin pyproject failed with: exit code=1: cd /build/reproducible-path/pytest-mypy-testing-0.1.3/.pybuild/cpython3_3.13/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:6: binary] Error 25 dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2 I: copying local configuration E: Failed autobuilding of package I: unmounting dev/ptmx filesystem I: unmounting dev/pts filesystem I: unmounting dev/shm filesystem I: unmounting proc filesystem I: unmounting sys filesystem I: cleaning the build env I: removing directory /srv/workspace/pbuilder/2991198 and its subdirectories Thu Aug 28 20:02:33 UTC 2025 W: No second build log, what happened?