I: pbuilder: network access will be disabled during build I: Current time: Thu Dec 12 20:45:03 +14 2024 I: pbuilder-time-stamp: 1733985903 I: Building the build Environment I: extracting base tarball [/var/cache/pbuilder/unstable-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: using eatmydata during job I: Copying source file I: copying [python-cheroot_10.0.1+ds1-2.dsc] I: copying [./python-cheroot_10.0.1+ds1.orig.tar.xz] I: copying [./python-cheroot_10.0.1+ds1-2.debian.tar.xz] I: Extracting source gpgv: Signature made Wed Dec 11 19:55:19 2024 gpgv: using RSA key AC0A4FF12611B6FCCF01C111393587D97D86500B gpgv: Can't check signature: No public key dpkg-source: warning: cannot verify inline signature for ./python-cheroot_10.0.1+ds1-2.dsc: no acceptable signature found dpkg-source: info: extracting python-cheroot in python-cheroot-10.0.1+ds1 dpkg-source: info: unpacking python-cheroot_10.0.1+ds1.orig.tar.xz dpkg-source: info: unpacking python-cheroot_10.0.1+ds1-2.debian.tar.xz dpkg-source: info: using patch list from debian/patches/series dpkg-source: info: applying pep440_version_number.patch dpkg-source: info: applying Remove-dependency-on-pypytools.patch dpkg-source: info: applying Skip-test_high_number_of_file_descriptors.patch dpkg-source: info: applying suppress-pytest-unraisable-exception-warning.patch I: Not using root during the build. I: Installing the build-deps I: user script /srv/workspace/pbuilder/36977/tmp/hooks/D01_modify_environment starting debug: Running on ionos2-i386. I: Changing host+domainname to test build reproducibility I: Adding a custom variable just for the fun of it... I: Changing /bin/sh to bash '/bin/sh' -> '/bin/bash' lrwxrwxrwx 1 root root 9 Dec 12 06:45 /bin/sh -> /bin/bash I: Setting pbuilder2's login shell to /bin/bash I: Setting pbuilder2's GECOS to second user,second room,second work-phone,second home-phone,second other I: user script /srv/workspace/pbuilder/36977/tmp/hooks/D01_modify_environment finished I: user script /srv/workspace/pbuilder/36977/tmp/hooks/D02_print_environment starting I: set BASH=/bin/sh BASHOPTS=checkwinsize:cmdhist:complete_fullquote:extquote:force_fignore:globasciiranges:globskipdots:hostcomplete:interactive_comments:patsub_replacement:progcomp:promptvars:sourcepath BASH_ALIASES=() BASH_ARGC=() BASH_ARGV=() BASH_CMDS=() BASH_LINENO=([0]="12" [1]="0") BASH_LOADABLES_PATH=/usr/local/lib/bash:/usr/lib/bash:/opt/local/lib/bash:/usr/pkg/lib/bash:/opt/pkg/lib/bash:. BASH_SOURCE=([0]="/tmp/hooks/D02_print_environment" [1]="/tmp/hooks/D02_print_environment") BASH_VERSINFO=([0]="5" [1]="2" [2]="37" [3]="1" [4]="release" [5]="i686-pc-linux-gnu") BASH_VERSION='5.2.37(1)-release' BUILDDIR=/build/reproducible-path BUILDUSERGECOS='second user,second room,second work-phone,second home-phone,second other' BUILDUSERNAME=pbuilder2 BUILD_ARCH=i386 DEBIAN_FRONTEND=noninteractive DEB_BUILD_OPTIONS='buildinfo=+all reproducible=+all parallel=10 ' DIRSTACK=() DISTRIBUTION=unstable EUID=0 FUNCNAME=([0]="Echo" [1]="main") GROUPS=() HOME=/root HOSTNAME=i-capture-the-hostname HOSTTYPE=i686 HOST_ARCH=i386 IFS=' ' INVOCATION_ID=c8c0cf36393f45c386949edd53a4858f LANG=C LANGUAGE=de_CH:de LC_ALL=C LD_LIBRARY_PATH=/usr/lib/libeatmydata LD_PRELOAD=libeatmydata.so MACHTYPE=i686-pc-linux-gnu MAIL=/var/mail/root OPTERR=1 OPTIND=1 OSTYPE=linux-gnu PATH=/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path PBCURRENTCOMMANDLINEOPERATION=build PBUILDER_OPERATION=build PBUILDER_PKGDATADIR=/usr/share/pbuilder PBUILDER_PKGLIBDIR=/usr/lib/pbuilder PBUILDER_SYSCONFDIR=/etc PIPESTATUS=([0]="0") POSIXLY_CORRECT=y PPID=36977 PS4='+ ' PWD=/ SHELL=/bin/bash SHELLOPTS=braceexpand:errexit:hashall:interactive-comments:posix SHLVL=3 SUDO_COMMAND='/usr/bin/timeout -k 24.1h 24h /usr/bin/ionice -c 3 /usr/bin/nice -n 11 /usr/bin/unshare --uts -- /usr/sbin/pbuilder --build --configfile /srv/reproducible-results/rbuild-debian/r-b-build.tVmZx4Jh/pbuilderrc_Nozz --distribution unstable --hookdir /etc/pbuilder/rebuild-hooks --debbuildopts -b --basetgz /var/cache/pbuilder/unstable-reproducible-base.tgz --buildresult /srv/reproducible-results/rbuild-debian/r-b-build.tVmZx4Jh/b2 --logfile b2/build.log python-cheroot_10.0.1+ds1-2.dsc' SUDO_GID=112 SUDO_UID=107 SUDO_USER=jenkins TERM=unknown TZ=/usr/share/zoneinfo/Etc/GMT-14 UID=0 USER=root _='I: set' http_proxy=http://46.16.76.132:3128 I: uname -a Linux i-capture-the-hostname 6.1.0-28-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.119-1 (2024-11-22) x86_64 GNU/Linux I: ls -l /bin lrwxrwxrwx 1 root root 7 Nov 22 14:40 /bin -> usr/bin I: user script /srv/workspace/pbuilder/36977/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: i386 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, pybuild-plugin-pyproject, python3-all, python3-jaraco.context, python3-jaraco.functools, python3-jaraco.text, python3-more-itertools, python3-openssl, python3-packaging, python3-portend, python3-pytest, python3-pytest-cov, python3-pytest-forked, python3-pytest-mock, python3-pytest-rerunfailures, python3-pytest-xdist, python3-requests-toolbelt, python3-requests-unixsocket, python3-setuptools, python3-setuptools-scm (>> 7), python3-sphinx, python3-trustme dpkg-deb: building package 'pbuilder-satisfydepends-dummy' in '/tmp/satisfydepends-aptitude/pbuilder-satisfydepends-dummy.deb'. Selecting previously unselected package pbuilder-satisfydepends-dummy. (Reading database ... 19952 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 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-jaraco.context; however: Package python3-jaraco.context is not installed. pbuilder-satisfydepends-dummy depends on python3-jaraco.functools; however: Package python3-jaraco.functools is not installed. pbuilder-satisfydepends-dummy depends on python3-jaraco.text; however: Package python3-jaraco.text is not installed. pbuilder-satisfydepends-dummy depends on python3-more-itertools; however: Package python3-more-itertools is not installed. pbuilder-satisfydepends-dummy depends on python3-openssl; however: Package python3-openssl is not installed. pbuilder-satisfydepends-dummy depends on python3-packaging; however: Package python3-packaging is not installed. pbuilder-satisfydepends-dummy depends on python3-portend; however: Package python3-portend is not installed. pbuilder-satisfydepends-dummy depends on python3-pytest; however: Package python3-pytest is not installed. pbuilder-satisfydepends-dummy depends on python3-pytest-cov; however: Package python3-pytest-cov is not installed. pbuilder-satisfydepends-dummy depends on python3-pytest-forked; however: Package python3-pytest-forked is not installed. pbuilder-satisfydepends-dummy depends on python3-pytest-mock; however: Package python3-pytest-mock is not installed. pbuilder-satisfydepends-dummy depends on python3-pytest-rerunfailures; however: Package python3-pytest-rerunfailures is not installed. pbuilder-satisfydepends-dummy depends on python3-pytest-xdist; however: Package python3-pytest-xdist is not installed. pbuilder-satisfydepends-dummy depends on python3-requests-toolbelt; however: Package python3-requests-toolbelt is not installed. pbuilder-satisfydepends-dummy depends on python3-requests-unixsocket; however: Package python3-requests-unixsocket is not installed. pbuilder-satisfydepends-dummy depends on python3-setuptools; however: Package python3-setuptools is not installed. pbuilder-satisfydepends-dummy depends on python3-setuptools-scm (>> 7); however: Package python3-setuptools-scm is not installed. pbuilder-satisfydepends-dummy depends on python3-sphinx; however: Package python3-sphinx is not installed. pbuilder-satisfydepends-dummy depends on python3-trustme; however: Package python3-trustme 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} gettext{a} gettext-base{a} groff-base{a} intltool-debian{a} libarchive-zip-perl{a} libcom-err2{a} libdebhelper-perl{a} libelf1t64{a} libexpat1{a} libfile-stripnondeterminism-perl{a} libgssapi-krb5-2{a} libicu72{a} libjs-jquery{a} libjs-jquery-hotkeys{a} libjs-jquery-isonscreen{a} libjs-jquery-metadata{a} libjs-jquery-tablesorter{a} libjs-jquery-throttle-debounce{a} libjs-sphinxdoc{a} libjs-underscore{a} libjson-perl{a} libk5crypto3{a} libkeyutils1{a} libkrb5-3{a} libkrb5support0{a} libmagic-mgc{a} libmagic1t64{a} libnsl2{a} libpipeline1{a} libpython3-stdlib{a} libpython3.12-minimal{a} libpython3.12-stdlib{a} libpython3.13-minimal{a} libpython3.13-stdlib{a} libreadline8t64{a} libtirpc-common{a} libtirpc3t64{a} libtool{a} libuchardet0{a} libxml2{a} m4{a} man-db{a} media-types{a} netbase{a} openssl{a} po-debconf{a} pybuild-plugin-pyproject{a} python-babel-localedata{a} python3{a} python3-alabaster{a} python3-all{a} python3-autocommand{a} python3-babel{a} python3-bcrypt{a} python3-build{a} python3-certifi{a} python3-cffi-backend{a} python3-chardet{a} python3-charset-normalizer{a} python3-coverage{a} python3-cryptography{a} python3-dateutil{a} python3-defusedxml{a} python3-docutils{a} python3-execnet{a} python3-idna{a} python3-imagesize{a} python3-inflect{a} python3-iniconfig{a} python3-installer{a} python3-jaraco.context{a} python3-jaraco.functools{a} python3-jaraco.text{a} python3-jinja2{a} python3-markupsafe{a} python3-minimal{a} python3-more-itertools{a} python3-openssl{a} python3-packaging{a} python3-pkg-resources{a} python3-pluggy{a} python3-portend{a} python3-py{a} python3-pygments{a} python3-pyproject-hooks{a} python3-pytest{a} python3-pytest-cov{a} python3-pytest-forked{a} python3-pytest-mock{a} python3-pytest-rerunfailures{a} python3-pytest-xdist{a} python3-requests{a} python3-requests-toolbelt{a} python3-requests-unixsocket{a} python3-roman{a} python3-setuptools{a} python3-setuptools-scm{a} python3-snowballstemmer{a} python3-sphinx{a} python3-tempora{a} python3-toml{a} python3-trustme{a} python3-typeguard{a} python3-typing-extensions{a} python3-urllib3{a} python3-wheel{a} python3-zipp{a} python3.12{a} python3.12-minimal{a} python3.13{a} python3.13-minimal{a} readline-common{a} sensible-utils{a} sgml-base{a} sphinx-common{a} tzdata{a} xml-core{a} The following packages are RECOMMENDED but will NOT be installed: curl javascript-common krb5-locales libarchive-cpio-perl libjson-xs-perl libltdl-dev libmail-sendmail-perl libpaper-utils lynx python3-pil wget 0 packages upgraded, 130 newly installed, 0 to remove and 0 not upgraded. Need to get 48.3 MB of archives. After unpacking 197 MB will be used. Writing extended state information... Get: 1 http://deb.debian.org/debian unstable/main i386 libjs-jquery all 3.6.1+dfsg+~3.5.14-1 [326 kB] Get: 2 http://deb.debian.org/debian unstable/main i386 libjs-jquery-hotkeys all 0~20130707+git2d51e3a9+dfsg-2.1 [11.5 kB] Get: 3 http://deb.debian.org/debian unstable/main i386 libpython3.12-minimal i386 3.12.8-1 [815 kB] Get: 4 http://deb.debian.org/debian unstable/main i386 libexpat1 i386 2.6.4-1 [107 kB] Get: 5 http://deb.debian.org/debian unstable/main i386 python3.12-minimal i386 3.12.8-1 [2240 kB] Get: 6 http://deb.debian.org/debian unstable/main i386 python3-minimal i386 3.12.7-1 [26.8 kB] Get: 7 http://deb.debian.org/debian unstable/main i386 media-types all 10.1.0 [26.9 kB] Get: 8 http://deb.debian.org/debian unstable/main i386 netbase all 6.4 [12.8 kB] Get: 9 http://deb.debian.org/debian unstable/main i386 tzdata all 2024b-4 [256 kB] Get: 10 http://deb.debian.org/debian unstable/main i386 libkrb5support0 i386 1.21.3-3 [34.9 kB] Get: 11 http://deb.debian.org/debian unstable/main i386 libcom-err2 i386 1.47.2~rc1-2 [24.0 kB] Get: 12 http://deb.debian.org/debian unstable/main i386 libk5crypto3 i386 1.21.3-3 [83.6 kB] Get: 13 http://deb.debian.org/debian unstable/main i386 libkeyutils1 i386 1.6.3-4 [9600 B] Get: 14 http://deb.debian.org/debian unstable/main i386 libkrb5-3 i386 1.21.3-3 [350 kB] Get: 15 http://deb.debian.org/debian unstable/main i386 libgssapi-krb5-2 i386 1.21.3-3 [146 kB] Get: 16 http://deb.debian.org/debian unstable/main i386 libtirpc-common all 1.3.4+ds-1.3 [10.9 kB] Get: 17 http://deb.debian.org/debian unstable/main i386 libtirpc3t64 i386 1.3.4+ds-1.3+b1 [90.5 kB] Get: 18 http://deb.debian.org/debian unstable/main i386 libnsl2 i386 1.3.0-3+b3 [42.7 kB] Get: 19 http://deb.debian.org/debian unstable/main i386 readline-common all 8.2-5 [69.3 kB] Get: 20 http://deb.debian.org/debian unstable/main i386 libreadline8t64 i386 8.2-5 [173 kB] Get: 21 http://deb.debian.org/debian unstable/main i386 libpython3.12-stdlib i386 3.12.8-1 [1968 kB] Get: 22 http://deb.debian.org/debian unstable/main i386 python3.12 i386 3.12.8-1 [677 kB] Get: 23 http://deb.debian.org/debian unstable/main i386 libpython3-stdlib i386 3.12.7-1 [9712 B] Get: 24 http://deb.debian.org/debian unstable/main i386 python3 i386 3.12.7-1 [27.8 kB] Get: 25 http://deb.debian.org/debian unstable/main i386 libpython3.13-minimal i386 3.13.1-1 [856 kB] Get: 26 http://deb.debian.org/debian unstable/main i386 python3.13-minimal i386 3.13.1-1 [2261 kB] Get: 27 http://deb.debian.org/debian unstable/main i386 sgml-base all 1.31 [15.4 kB] Get: 28 http://deb.debian.org/debian unstable/main i386 sensible-utils all 0.0.24 [24.8 kB] Get: 29 http://deb.debian.org/debian unstable/main i386 openssl i386 3.3.2-2 [1387 kB] Get: 30 http://deb.debian.org/debian unstable/main i386 ca-certificates all 20240203 [158 kB] Get: 31 http://deb.debian.org/debian unstable/main i386 libmagic-mgc i386 1:5.45-3+b1 [314 kB] Get: 32 http://deb.debian.org/debian unstable/main i386 libmagic1t64 i386 1:5.45-3+b1 [115 kB] Get: 33 http://deb.debian.org/debian unstable/main i386 file i386 1:5.45-3+b1 [43.2 kB] Get: 34 http://deb.debian.org/debian unstable/main i386 gettext-base i386 0.22.5-2 [201 kB] Get: 35 http://deb.debian.org/debian unstable/main i386 libuchardet0 i386 0.0.8-1+b2 [69.2 kB] Get: 36 http://deb.debian.org/debian unstable/main i386 groff-base i386 1.23.0-6 [1198 kB] Get: 37 http://deb.debian.org/debian unstable/main i386 bsdextrautils i386 2.40.2-12 [95.9 kB] Get: 38 http://deb.debian.org/debian unstable/main i386 libpipeline1 i386 1.5.8-1 [41.2 kB] Get: 39 http://deb.debian.org/debian unstable/main i386 man-db i386 2.13.0-1 [1428 kB] Get: 40 http://deb.debian.org/debian unstable/main i386 m4 i386 1.4.19-4 [293 kB] Get: 41 http://deb.debian.org/debian unstable/main i386 autoconf all 2.72-3 [493 kB] Get: 42 http://deb.debian.org/debian unstable/main i386 autotools-dev all 20220109.1 [51.6 kB] Get: 43 http://deb.debian.org/debian unstable/main i386 automake all 1:1.16.5-1.3 [823 kB] Get: 44 http://deb.debian.org/debian unstable/main i386 autopoint all 0.22.5-2 [723 kB] Get: 45 http://deb.debian.org/debian unstable/main i386 libdebhelper-perl all 13.20 [89.7 kB] Get: 46 http://deb.debian.org/debian unstable/main i386 libtool all 2.4.7-8 [517 kB] Get: 47 http://deb.debian.org/debian unstable/main i386 dh-autoreconf all 20 [17.1 kB] Get: 48 http://deb.debian.org/debian unstable/main i386 libarchive-zip-perl all 1.68-1 [104 kB] Get: 49 http://deb.debian.org/debian unstable/main i386 libfile-stripnondeterminism-perl all 1.14.0-1 [19.5 kB] Get: 50 http://deb.debian.org/debian unstable/main i386 dh-strip-nondeterminism all 1.14.0-1 [8448 B] Get: 51 http://deb.debian.org/debian unstable/main i386 libelf1t64 i386 0.192-4 [195 kB] Get: 52 http://deb.debian.org/debian unstable/main i386 dwz i386 0.15-1+b1 [116 kB] Get: 53 http://deb.debian.org/debian unstable/main i386 libicu72 i386 72.1-5+b1 [9583 kB] Get: 54 http://deb.debian.org/debian unstable/main i386 libxml2 i386 2.12.7+dfsg+really2.9.14-0.2+b1 [734 kB] Get: 55 http://deb.debian.org/debian unstable/main i386 gettext i386 0.22.5-2 [1631 kB] Get: 56 http://deb.debian.org/debian unstable/main i386 intltool-debian all 0.35.0+20060710.6 [22.9 kB] Get: 57 http://deb.debian.org/debian unstable/main i386 po-debconf all 1.0.21+nmu1 [248 kB] Get: 58 http://deb.debian.org/debian unstable/main i386 debhelper all 13.20 [915 kB] Get: 59 http://deb.debian.org/debian unstable/main i386 python3-autocommand all 2.2.2-3 [13.6 kB] Get: 60 http://deb.debian.org/debian unstable/main i386 python3-more-itertools all 10.5.0-1 [63.8 kB] Get: 61 http://deb.debian.org/debian unstable/main i386 python3-typing-extensions all 4.12.2-2 [73.0 kB] Get: 62 http://deb.debian.org/debian unstable/main i386 python3-typeguard all 4.4.1-1 [37.0 kB] Get: 63 http://deb.debian.org/debian unstable/main i386 python3-inflect all 7.3.1-2 [32.4 kB] Get: 64 http://deb.debian.org/debian unstable/main i386 python3-jaraco.context all 6.0.0-1 [7984 B] Get: 65 http://deb.debian.org/debian unstable/main i386 python3-jaraco.functools all 4.1.0-1 [12.0 kB] Get: 66 http://deb.debian.org/debian unstable/main i386 python3-pkg-resources all 75.2.0-1 [213 kB] Get: 67 http://deb.debian.org/debian unstable/main i386 python3-jaraco.text all 4.0.0-1 [11.4 kB] Get: 68 http://deb.debian.org/debian unstable/main i386 python3-zipp all 3.21.0-1 [10.6 kB] Get: 69 http://deb.debian.org/debian unstable/main i386 python3-setuptools all 75.2.0-1 [731 kB] Get: 70 http://deb.debian.org/debian unstable/main i386 dh-python all 6.20241024 [109 kB] Get: 71 http://deb.debian.org/debian unstable/main i386 xml-core all 0.19 [20.1 kB] Get: 72 http://deb.debian.org/debian unstable/main i386 docutils-common all 0.21.2+dfsg-2 [128 kB] Get: 73 http://deb.debian.org/debian unstable/main i386 libjs-jquery-isonscreen all 1.2.0-1.1 [3196 B] Get: 74 http://deb.debian.org/debian unstable/main i386 libjs-jquery-metadata all 12-4 [6532 B] Get: 75 http://deb.debian.org/debian unstable/main i386 libjs-jquery-tablesorter all 1:2.31.3+dfsg1-4 [184 kB] Get: 76 http://deb.debian.org/debian unstable/main i386 libjs-jquery-throttle-debounce all 1.1+dfsg.1-2 [12.2 kB] Get: 77 http://deb.debian.org/debian unstable/main i386 libjs-underscore all 1.13.4~dfsg+~1.11.4-3 [116 kB] Get: 78 http://deb.debian.org/debian unstable/main i386 libjs-sphinxdoc all 8.1.3-2 [30.3 kB] Get: 79 http://deb.debian.org/debian unstable/main i386 libjson-perl all 4.10000-1 [87.5 kB] Get: 80 http://deb.debian.org/debian unstable/main i386 libpython3.13-stdlib i386 3.13.1-1 [1979 kB] Get: 81 http://deb.debian.org/debian unstable/main i386 python3-packaging all 24.2-1 [55.3 kB] Get: 82 http://deb.debian.org/debian unstable/main i386 python3-pyproject-hooks all 1.2.0-1 [11.7 kB] Get: 83 http://deb.debian.org/debian unstable/main i386 python3-toml all 0.10.2-1 [16.2 kB] Get: 84 http://deb.debian.org/debian unstable/main i386 python3-wheel all 0.45.1-1 [56.7 kB] Get: 85 http://deb.debian.org/debian unstable/main i386 python3-build all 1.2.2-1 [36.0 kB] Get: 86 http://deb.debian.org/debian unstable/main i386 python3-installer all 0.7.0+dfsg1-3 [18.6 kB] Get: 87 http://deb.debian.org/debian unstable/main i386 pybuild-plugin-pyproject all 6.20241024 [11.4 kB] Get: 88 http://deb.debian.org/debian unstable/main i386 python-babel-localedata all 2.16.0-1 [5696 kB] Get: 89 http://deb.debian.org/debian unstable/main i386 python3-alabaster all 0.7.16-0.1 [27.9 kB] Get: 90 http://deb.debian.org/debian unstable/main i386 python3.13 i386 3.13.1-1 [740 kB] Get: 91 http://deb.debian.org/debian unstable/main i386 python3-all i386 3.12.7-1 [1052 B] Get: 92 http://deb.debian.org/debian unstable/main i386 python3-babel all 2.16.0-1 [114 kB] Get: 93 http://deb.debian.org/debian unstable/main i386 python3-bcrypt i386 4.2.0-2.1 [248 kB] Get: 94 http://deb.debian.org/debian unstable/main i386 python3-certifi all 2024.8.30+dfsg-1 [9576 B] Get: 95 http://deb.debian.org/debian unstable/main i386 python3-cffi-backend i386 1.17.1-2+b1 [95.5 kB] Get: 96 http://deb.debian.org/debian unstable/main i386 python3-chardet all 5.2.0+dfsg-1 [107 kB] Get: 97 http://deb.debian.org/debian unstable/main i386 python3-charset-normalizer i386 3.4.0-1+b1 [139 kB] Get: 98 http://deb.debian.org/debian unstable/main i386 python3-coverage i386 7.6.0+dfsg1-2+b1 [177 kB] Get: 99 http://deb.debian.org/debian unstable/main i386 python3-cryptography i386 43.0.0-1 [975 kB] Get: 100 http://deb.debian.org/debian unstable/main i386 python3-dateutil all 2.9.0-3 [79.3 kB] Get: 101 http://deb.debian.org/debian unstable/main i386 python3-defusedxml all 0.7.1-3 [43.4 kB] Get: 102 http://deb.debian.org/debian unstable/main i386 python3-roman all 4.2-1 [10.4 kB] Get: 103 http://deb.debian.org/debian unstable/main i386 python3-docutils all 0.21.2+dfsg-2 [403 kB] Get: 104 http://deb.debian.org/debian unstable/main i386 python3-execnet all 2.1.1-1 [40.2 kB] Get: 105 http://deb.debian.org/debian unstable/main i386 python3-idna all 3.8-2 [41.6 kB] Get: 106 http://deb.debian.org/debian unstable/main i386 python3-imagesize all 1.4.1-1 [6688 B] Get: 107 http://deb.debian.org/debian unstable/main i386 python3-iniconfig all 1.1.1-2 [6396 B] Get: 108 http://deb.debian.org/debian unstable/main i386 python3-markupsafe i386 2.1.5-1+b2 [13.9 kB] Get: 109 http://deb.debian.org/debian unstable/main i386 python3-jinja2 all 3.1.3-1 [119 kB] Get: 110 http://deb.debian.org/debian unstable/main i386 python3-openssl all 24.3.0-1 [51.7 kB] Get: 111 http://deb.debian.org/debian unstable/main i386 python3-pluggy all 1.5.0-1 [26.9 kB] Get: 112 http://deb.debian.org/debian unstable/main i386 python3-tempora all 5.7.0-2 [15.1 kB] Get: 113 http://deb.debian.org/debian unstable/main i386 python3-portend all 3.2.0-1 [7528 B] Get: 114 http://deb.debian.org/debian unstable/main i386 python3-py all 1.11.0-2 [88.7 kB] Get: 115 http://deb.debian.org/debian unstable/main i386 python3-pygments all 2.18.0+dfsg-1 [836 kB] Get: 116 http://deb.debian.org/debian unstable/main i386 python3-pytest all 8.3.4-1 [250 kB] Get: 117 http://deb.debian.org/debian unstable/main i386 python3-pytest-cov all 5.0.0-1 [26.8 kB] Get: 118 http://deb.debian.org/debian unstable/main i386 python3-pytest-forked all 1.6.0-2 [7804 B] Get: 119 http://deb.debian.org/debian unstable/main i386 python3-pytest-mock all 3.14.0-2 [18.3 kB] Get: 120 http://deb.debian.org/debian unstable/main i386 python3-pytest-rerunfailures all 14.0-2 [16.5 kB] Get: 121 http://deb.debian.org/debian unstable/main i386 python3-pytest-xdist all 3.6.1-1 [44.4 kB] Get: 122 http://deb.debian.org/debian unstable/main i386 python3-urllib3 all 2.2.3-4 [112 kB] Get: 123 http://deb.debian.org/debian unstable/main i386 python3-requests all 2.32.3+dfsg-1 [71.9 kB] Get: 124 http://deb.debian.org/debian unstable/main i386 python3-requests-toolbelt all 1.0.0-3 [40.2 kB] Get: 125 http://deb.debian.org/debian unstable/main i386 python3-requests-unixsocket all 0.3.0-5 [7364 B] Get: 126 http://deb.debian.org/debian unstable/main i386 python3-setuptools-scm all 8.1.0-1 [40.5 kB] Get: 127 http://deb.debian.org/debian unstable/main i386 python3-snowballstemmer all 2.2.0-4 [58.0 kB] Get: 128 http://deb.debian.org/debian unstable/main i386 sphinx-common all 8.1.3-2 [616 kB] Get: 129 http://deb.debian.org/debian unstable/main i386 python3-sphinx all 8.1.3-2 [468 kB] Get: 130 http://deb.debian.org/debian unstable/main i386 python3-trustme all 1.2.0-2 [12.2 kB] Fetched 48.3 MB in 1s (33.6 MB/s) debconf: delaying package configuration, since apt-utils is not installed Selecting previously unselected package libjs-jquery. (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 ... 19952 files and directories currently installed.) Preparing to unpack .../libjs-jquery_3.6.1+dfsg+~3.5.14-1_all.deb ... Unpacking libjs-jquery (3.6.1+dfsg+~3.5.14-1) ... Selecting previously unselected package libjs-jquery-hotkeys. Preparing to unpack .../libjs-jquery-hotkeys_0~20130707+git2d51e3a9+dfsg-2.1_all.deb ... Unpacking libjs-jquery-hotkeys (0~20130707+git2d51e3a9+dfsg-2.1) ... Selecting previously unselected package libpython3.12-minimal:i386. Preparing to unpack .../libpython3.12-minimal_3.12.8-1_i386.deb ... Unpacking libpython3.12-minimal:i386 (3.12.8-1) ... Selecting previously unselected package libexpat1:i386. Preparing to unpack .../libexpat1_2.6.4-1_i386.deb ... Unpacking libexpat1:i386 (2.6.4-1) ... Selecting previously unselected package python3.12-minimal. Preparing to unpack .../python3.12-minimal_3.12.8-1_i386.deb ... Unpacking python3.12-minimal (3.12.8-1) ... Setting up libpython3.12-minimal:i386 (3.12.8-1) ... Setting up libexpat1:i386 (2.6.4-1) ... Setting up python3.12-minimal (3.12.8-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 ... 20298 files and directories currently installed.) Preparing to unpack .../00-python3-minimal_3.12.7-1_i386.deb ... Unpacking python3-minimal (3.12.7-1) ... Selecting previously unselected package media-types. Preparing to unpack .../01-media-types_10.1.0_all.deb ... Unpacking media-types (10.1.0) ... Selecting previously unselected package netbase. Preparing to unpack .../02-netbase_6.4_all.deb ... Unpacking netbase (6.4) ... Selecting previously unselected package tzdata. Preparing to unpack .../03-tzdata_2024b-4_all.deb ... Unpacking tzdata (2024b-4) ... Selecting previously unselected package libkrb5support0:i386. Preparing to unpack .../04-libkrb5support0_1.21.3-3_i386.deb ... Unpacking libkrb5support0:i386 (1.21.3-3) ... Selecting previously unselected package libcom-err2:i386. Preparing to unpack .../05-libcom-err2_1.47.2~rc1-2_i386.deb ... Unpacking libcom-err2:i386 (1.47.2~rc1-2) ... Selecting previously unselected package libk5crypto3:i386. Preparing to unpack .../06-libk5crypto3_1.21.3-3_i386.deb ... Unpacking libk5crypto3:i386 (1.21.3-3) ... Selecting previously unselected package libkeyutils1:i386. Preparing to unpack .../07-libkeyutils1_1.6.3-4_i386.deb ... Unpacking libkeyutils1:i386 (1.6.3-4) ... Selecting previously unselected package libkrb5-3:i386. Preparing to unpack .../08-libkrb5-3_1.21.3-3_i386.deb ... Unpacking libkrb5-3:i386 (1.21.3-3) ... Selecting previously unselected package libgssapi-krb5-2:i386. Preparing to unpack .../09-libgssapi-krb5-2_1.21.3-3_i386.deb ... Unpacking libgssapi-krb5-2:i386 (1.21.3-3) ... Selecting previously unselected package libtirpc-common. Preparing to unpack .../10-libtirpc-common_1.3.4+ds-1.3_all.deb ... Unpacking libtirpc-common (1.3.4+ds-1.3) ... Selecting previously unselected package libtirpc3t64:i386. Preparing to unpack .../11-libtirpc3t64_1.3.4+ds-1.3+b1_i386.deb ... Adding 'diversion of /lib/i386-linux-gnu/libtirpc.so.3 to /lib/i386-linux-gnu/libtirpc.so.3.usr-is-merged by libtirpc3t64' Adding 'diversion of /lib/i386-linux-gnu/libtirpc.so.3.0.0 to /lib/i386-linux-gnu/libtirpc.so.3.0.0.usr-is-merged by libtirpc3t64' Unpacking libtirpc3t64:i386 (1.3.4+ds-1.3+b1) ... Selecting previously unselected package libnsl2:i386. Preparing to unpack .../12-libnsl2_1.3.0-3+b3_i386.deb ... Unpacking libnsl2:i386 (1.3.0-3+b3) ... Selecting previously unselected package readline-common. Preparing to unpack .../13-readline-common_8.2-5_all.deb ... Unpacking readline-common (8.2-5) ... Selecting previously unselected package libreadline8t64:i386. Preparing to unpack .../14-libreadline8t64_8.2-5_i386.deb ... Adding 'diversion of /lib/i386-linux-gnu/libhistory.so.8 to /lib/i386-linux-gnu/libhistory.so.8.usr-is-merged by libreadline8t64' Adding 'diversion of /lib/i386-linux-gnu/libhistory.so.8.2 to /lib/i386-linux-gnu/libhistory.so.8.2.usr-is-merged by libreadline8t64' Adding 'diversion of /lib/i386-linux-gnu/libreadline.so.8 to /lib/i386-linux-gnu/libreadline.so.8.usr-is-merged by libreadline8t64' Adding 'diversion of /lib/i386-linux-gnu/libreadline.so.8.2 to /lib/i386-linux-gnu/libreadline.so.8.2.usr-is-merged by libreadline8t64' Unpacking libreadline8t64:i386 (8.2-5) ... Selecting previously unselected package libpython3.12-stdlib:i386. Preparing to unpack .../15-libpython3.12-stdlib_3.12.8-1_i386.deb ... Unpacking libpython3.12-stdlib:i386 (3.12.8-1) ... Selecting previously unselected package python3.12. Preparing to unpack .../16-python3.12_3.12.8-1_i386.deb ... Unpacking python3.12 (3.12.8-1) ... Selecting previously unselected package libpython3-stdlib:i386. Preparing to unpack .../17-libpython3-stdlib_3.12.7-1_i386.deb ... Unpacking libpython3-stdlib:i386 (3.12.7-1) ... Setting up python3-minimal (3.12.7-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 ... 21361 files and directories currently installed.) Preparing to unpack .../000-python3_3.12.7-1_i386.deb ... Unpacking python3 (3.12.7-1) ... Selecting previously unselected package libpython3.13-minimal:i386. Preparing to unpack .../001-libpython3.13-minimal_3.13.1-1_i386.deb ... Unpacking libpython3.13-minimal:i386 (3.13.1-1) ... Selecting previously unselected package python3.13-minimal. Preparing to unpack .../002-python3.13-minimal_3.13.1-1_i386.deb ... Unpacking python3.13-minimal (3.13.1-1) ... Selecting previously unselected package sgml-base. Preparing to unpack .../003-sgml-base_1.31_all.deb ... Unpacking sgml-base (1.31) ... Selecting previously unselected package sensible-utils. Preparing to unpack .../004-sensible-utils_0.0.24_all.deb ... Unpacking sensible-utils (0.0.24) ... Selecting previously unselected package openssl. Preparing to unpack .../005-openssl_3.3.2-2_i386.deb ... Unpacking openssl (3.3.2-2) ... Selecting previously unselected package ca-certificates. Preparing to unpack .../006-ca-certificates_20240203_all.deb ... Unpacking ca-certificates (20240203) ... Selecting previously unselected package libmagic-mgc. Preparing to unpack .../007-libmagic-mgc_1%3a5.45-3+b1_i386.deb ... Unpacking libmagic-mgc (1:5.45-3+b1) ... Selecting previously unselected package libmagic1t64:i386. Preparing to unpack .../008-libmagic1t64_1%3a5.45-3+b1_i386.deb ... Unpacking libmagic1t64:i386 (1:5.45-3+b1) ... Selecting previously unselected package file. Preparing to unpack .../009-file_1%3a5.45-3+b1_i386.deb ... Unpacking file (1:5.45-3+b1) ... Selecting previously unselected package gettext-base. Preparing to unpack .../010-gettext-base_0.22.5-2_i386.deb ... Unpacking gettext-base (0.22.5-2) ... Selecting previously unselected package libuchardet0:i386. Preparing to unpack .../011-libuchardet0_0.0.8-1+b2_i386.deb ... Unpacking libuchardet0:i386 (0.0.8-1+b2) ... Selecting previously unselected package groff-base. Preparing to unpack .../012-groff-base_1.23.0-6_i386.deb ... Unpacking groff-base (1.23.0-6) ... Selecting previously unselected package bsdextrautils. Preparing to unpack .../013-bsdextrautils_2.40.2-12_i386.deb ... Unpacking bsdextrautils (2.40.2-12) ... Selecting previously unselected package libpipeline1:i386. Preparing to unpack .../014-libpipeline1_1.5.8-1_i386.deb ... Unpacking libpipeline1:i386 (1.5.8-1) ... Selecting previously unselected package man-db. Preparing to unpack .../015-man-db_2.13.0-1_i386.deb ... Unpacking man-db (2.13.0-1) ... Selecting previously unselected package m4. Preparing to unpack .../016-m4_1.4.19-4_i386.deb ... Unpacking m4 (1.4.19-4) ... Selecting previously unselected package autoconf. Preparing to unpack .../017-autoconf_2.72-3_all.deb ... Unpacking autoconf (2.72-3) ... Selecting previously unselected package autotools-dev. Preparing to unpack .../018-autotools-dev_20220109.1_all.deb ... Unpacking autotools-dev (20220109.1) ... Selecting previously unselected package automake. Preparing to unpack .../019-automake_1%3a1.16.5-1.3_all.deb ... Unpacking automake (1:1.16.5-1.3) ... Selecting previously unselected package autopoint. Preparing to unpack .../020-autopoint_0.22.5-2_all.deb ... Unpacking autopoint (0.22.5-2) ... Selecting previously unselected package libdebhelper-perl. Preparing to unpack .../021-libdebhelper-perl_13.20_all.deb ... Unpacking libdebhelper-perl (13.20) ... Selecting previously unselected package libtool. Preparing to unpack .../022-libtool_2.4.7-8_all.deb ... Unpacking libtool (2.4.7-8) ... Selecting previously unselected package dh-autoreconf. Preparing to unpack .../023-dh-autoreconf_20_all.deb ... Unpacking dh-autoreconf (20) ... Selecting previously unselected package libarchive-zip-perl. Preparing to unpack .../024-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 .../025-libfile-stripnondeterminism-perl_1.14.0-1_all.deb ... Unpacking libfile-stripnondeterminism-perl (1.14.0-1) ... Selecting previously unselected package dh-strip-nondeterminism. Preparing to unpack .../026-dh-strip-nondeterminism_1.14.0-1_all.deb ... Unpacking dh-strip-nondeterminism (1.14.0-1) ... Selecting previously unselected package libelf1t64:i386. Preparing to unpack .../027-libelf1t64_0.192-4_i386.deb ... Unpacking libelf1t64:i386 (0.192-4) ... Selecting previously unselected package dwz. Preparing to unpack .../028-dwz_0.15-1+b1_i386.deb ... Unpacking dwz (0.15-1+b1) ... Selecting previously unselected package libicu72:i386. Preparing to unpack .../029-libicu72_72.1-5+b1_i386.deb ... Unpacking libicu72:i386 (72.1-5+b1) ... Selecting previously unselected package libxml2:i386. Preparing to unpack .../030-libxml2_2.12.7+dfsg+really2.9.14-0.2+b1_i386.deb ... Unpacking libxml2:i386 (2.12.7+dfsg+really2.9.14-0.2+b1) ... Selecting previously unselected package gettext. Preparing to unpack .../031-gettext_0.22.5-2_i386.deb ... Unpacking gettext (0.22.5-2) ... Selecting previously unselected package intltool-debian. Preparing to unpack .../032-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 .../033-po-debconf_1.0.21+nmu1_all.deb ... Unpacking po-debconf (1.0.21+nmu1) ... Selecting previously unselected package debhelper. Preparing to unpack .../034-debhelper_13.20_all.deb ... Unpacking debhelper (13.20) ... Selecting previously unselected package python3-autocommand. Preparing to unpack .../035-python3-autocommand_2.2.2-3_all.deb ... Unpacking python3-autocommand (2.2.2-3) ... Selecting previously unselected package python3-more-itertools. Preparing to unpack .../036-python3-more-itertools_10.5.0-1_all.deb ... Unpacking python3-more-itertools (10.5.0-1) ... Selecting previously unselected package python3-typing-extensions. Preparing to unpack .../037-python3-typing-extensions_4.12.2-2_all.deb ... Unpacking python3-typing-extensions (4.12.2-2) ... Selecting previously unselected package python3-typeguard. Preparing to unpack .../038-python3-typeguard_4.4.1-1_all.deb ... Unpacking python3-typeguard (4.4.1-1) ... Selecting previously unselected package python3-inflect. Preparing to unpack .../039-python3-inflect_7.3.1-2_all.deb ... Unpacking python3-inflect (7.3.1-2) ... Selecting previously unselected package python3-jaraco.context. Preparing to unpack .../040-python3-jaraco.context_6.0.0-1_all.deb ... Unpacking python3-jaraco.context (6.0.0-1) ... Selecting previously unselected package python3-jaraco.functools. Preparing to unpack .../041-python3-jaraco.functools_4.1.0-1_all.deb ... Unpacking python3-jaraco.functools (4.1.0-1) ... Selecting previously unselected package python3-pkg-resources. Preparing to unpack .../042-python3-pkg-resources_75.2.0-1_all.deb ... Unpacking python3-pkg-resources (75.2.0-1) ... Selecting previously unselected package python3-jaraco.text. Preparing to unpack .../043-python3-jaraco.text_4.0.0-1_all.deb ... Unpacking python3-jaraco.text (4.0.0-1) ... Selecting previously unselected package python3-zipp. Preparing to unpack .../044-python3-zipp_3.21.0-1_all.deb ... Unpacking python3-zipp (3.21.0-1) ... Selecting previously unselected package python3-setuptools. Preparing to unpack .../045-python3-setuptools_75.2.0-1_all.deb ... Unpacking python3-setuptools (75.2.0-1) ... Selecting previously unselected package dh-python. Preparing to unpack .../046-dh-python_6.20241024_all.deb ... Unpacking dh-python (6.20241024) ... Selecting previously unselected package xml-core. Preparing to unpack .../047-xml-core_0.19_all.deb ... Unpacking xml-core (0.19) ... Selecting previously unselected package docutils-common. Preparing to unpack .../048-docutils-common_0.21.2+dfsg-2_all.deb ... Unpacking docutils-common (0.21.2+dfsg-2) ... Selecting previously unselected package libjs-jquery-isonscreen. Preparing to unpack .../049-libjs-jquery-isonscreen_1.2.0-1.1_all.deb ... Unpacking libjs-jquery-isonscreen (1.2.0-1.1) ... Selecting previously unselected package libjs-jquery-metadata. Preparing to unpack .../050-libjs-jquery-metadata_12-4_all.deb ... Unpacking libjs-jquery-metadata (12-4) ... Selecting previously unselected package libjs-jquery-tablesorter. Preparing to unpack .../051-libjs-jquery-tablesorter_1%3a2.31.3+dfsg1-4_all.deb ... Unpacking libjs-jquery-tablesorter (1:2.31.3+dfsg1-4) ... Selecting previously unselected package libjs-jquery-throttle-debounce. Preparing to unpack .../052-libjs-jquery-throttle-debounce_1.1+dfsg.1-2_all.deb ... Unpacking libjs-jquery-throttle-debounce (1.1+dfsg.1-2) ... Selecting previously unselected package libjs-underscore. Preparing to unpack .../053-libjs-underscore_1.13.4~dfsg+~1.11.4-3_all.deb ... Unpacking libjs-underscore (1.13.4~dfsg+~1.11.4-3) ... Selecting previously unselected package libjs-sphinxdoc. Preparing to unpack .../054-libjs-sphinxdoc_8.1.3-2_all.deb ... Unpacking libjs-sphinxdoc (8.1.3-2) ... Selecting previously unselected package libjson-perl. Preparing to unpack .../055-libjson-perl_4.10000-1_all.deb ... Unpacking libjson-perl (4.10000-1) ... Selecting previously unselected package libpython3.13-stdlib:i386. Preparing to unpack .../056-libpython3.13-stdlib_3.13.1-1_i386.deb ... Unpacking libpython3.13-stdlib:i386 (3.13.1-1) ... Selecting previously unselected package python3-packaging. Preparing to unpack .../057-python3-packaging_24.2-1_all.deb ... Unpacking python3-packaging (24.2-1) ... Selecting previously unselected package python3-pyproject-hooks. Preparing to unpack .../058-python3-pyproject-hooks_1.2.0-1_all.deb ... Unpacking python3-pyproject-hooks (1.2.0-1) ... Selecting previously unselected package python3-toml. Preparing to unpack .../059-python3-toml_0.10.2-1_all.deb ... Unpacking python3-toml (0.10.2-1) ... Selecting previously unselected package python3-wheel. Preparing to unpack .../060-python3-wheel_0.45.1-1_all.deb ... Unpacking python3-wheel (0.45.1-1) ... Selecting previously unselected package python3-build. Preparing to unpack .../061-python3-build_1.2.2-1_all.deb ... Unpacking python3-build (1.2.2-1) ... Selecting previously unselected package python3-installer. Preparing to unpack .../062-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 .../063-pybuild-plugin-pyproject_6.20241024_all.deb ... Unpacking pybuild-plugin-pyproject (6.20241024) ... Selecting previously unselected package python-babel-localedata. Preparing to unpack .../064-python-babel-localedata_2.16.0-1_all.deb ... Unpacking python-babel-localedata (2.16.0-1) ... Selecting previously unselected package python3-alabaster. Preparing to unpack .../065-python3-alabaster_0.7.16-0.1_all.deb ... Unpacking python3-alabaster (0.7.16-0.1) ... Selecting previously unselected package python3.13. Preparing to unpack .../066-python3.13_3.13.1-1_i386.deb ... Unpacking python3.13 (3.13.1-1) ... Selecting previously unselected package python3-all. Preparing to unpack .../067-python3-all_3.12.7-1_i386.deb ... Unpacking python3-all (3.12.7-1) ... Selecting previously unselected package python3-babel. Preparing to unpack .../068-python3-babel_2.16.0-1_all.deb ... Unpacking python3-babel (2.16.0-1) ... Selecting previously unselected package python3-bcrypt. Preparing to unpack .../069-python3-bcrypt_4.2.0-2.1_i386.deb ... Unpacking python3-bcrypt (4.2.0-2.1) ... Selecting previously unselected package python3-certifi. Preparing to unpack .../070-python3-certifi_2024.8.30+dfsg-1_all.deb ... Unpacking python3-certifi (2024.8.30+dfsg-1) ... Selecting previously unselected package python3-cffi-backend:i386. Preparing to unpack .../071-python3-cffi-backend_1.17.1-2+b1_i386.deb ... Unpacking python3-cffi-backend:i386 (1.17.1-2+b1) ... Selecting previously unselected package python3-chardet. Preparing to unpack .../072-python3-chardet_5.2.0+dfsg-1_all.deb ... Unpacking python3-chardet (5.2.0+dfsg-1) ... Selecting previously unselected package python3-charset-normalizer. Preparing to unpack .../073-python3-charset-normalizer_3.4.0-1+b1_i386.deb ... Unpacking python3-charset-normalizer (3.4.0-1+b1) ... Selecting previously unselected package python3-coverage. Preparing to unpack .../074-python3-coverage_7.6.0+dfsg1-2+b1_i386.deb ... Unpacking python3-coverage (7.6.0+dfsg1-2+b1) ... Selecting previously unselected package python3-cryptography. Preparing to unpack .../075-python3-cryptography_43.0.0-1_i386.deb ... Unpacking python3-cryptography (43.0.0-1) ... Selecting previously unselected package python3-dateutil. Preparing to unpack .../076-python3-dateutil_2.9.0-3_all.deb ... Unpacking python3-dateutil (2.9.0-3) ... Selecting previously unselected package python3-defusedxml. Preparing to unpack .../077-python3-defusedxml_0.7.1-3_all.deb ... Unpacking python3-defusedxml (0.7.1-3) ... Selecting previously unselected package python3-roman. Preparing to unpack .../078-python3-roman_4.2-1_all.deb ... Unpacking python3-roman (4.2-1) ... Selecting previously unselected package python3-docutils. Preparing to unpack .../079-python3-docutils_0.21.2+dfsg-2_all.deb ... Unpacking python3-docutils (0.21.2+dfsg-2) ... Selecting previously unselected package python3-execnet. Preparing to unpack .../080-python3-execnet_2.1.1-1_all.deb ... Unpacking python3-execnet (2.1.1-1) ... Selecting previously unselected package python3-idna. Preparing to unpack .../081-python3-idna_3.8-2_all.deb ... Unpacking python3-idna (3.8-2) ... Selecting previously unselected package python3-imagesize. Preparing to unpack .../082-python3-imagesize_1.4.1-1_all.deb ... Unpacking python3-imagesize (1.4.1-1) ... Selecting previously unselected package python3-iniconfig. Preparing to unpack .../083-python3-iniconfig_1.1.1-2_all.deb ... Unpacking python3-iniconfig (1.1.1-2) ... Selecting previously unselected package python3-markupsafe. Preparing to unpack .../084-python3-markupsafe_2.1.5-1+b2_i386.deb ... Unpacking python3-markupsafe (2.1.5-1+b2) ... Selecting previously unselected package python3-jinja2. Preparing to unpack .../085-python3-jinja2_3.1.3-1_all.deb ... Unpacking python3-jinja2 (3.1.3-1) ... Selecting previously unselected package python3-openssl. Preparing to unpack .../086-python3-openssl_24.3.0-1_all.deb ... Unpacking python3-openssl (24.3.0-1) ... Selecting previously unselected package python3-pluggy. Preparing to unpack .../087-python3-pluggy_1.5.0-1_all.deb ... Unpacking python3-pluggy (1.5.0-1) ... Selecting previously unselected package python3-tempora. Preparing to unpack .../088-python3-tempora_5.7.0-2_all.deb ... Unpacking python3-tempora (5.7.0-2) ... Selecting previously unselected package python3-portend. Preparing to unpack .../089-python3-portend_3.2.0-1_all.deb ... Unpacking python3-portend (3.2.0-1) ... Selecting previously unselected package python3-py. Preparing to unpack .../090-python3-py_1.11.0-2_all.deb ... Unpacking python3-py (1.11.0-2) ... Selecting previously unselected package python3-pygments. Preparing to unpack .../091-python3-pygments_2.18.0+dfsg-1_all.deb ... Unpacking python3-pygments (2.18.0+dfsg-1) ... Selecting previously unselected package python3-pytest. Preparing to unpack .../092-python3-pytest_8.3.4-1_all.deb ... Unpacking python3-pytest (8.3.4-1) ... Selecting previously unselected package python3-pytest-cov. Preparing to unpack .../093-python3-pytest-cov_5.0.0-1_all.deb ... Unpacking python3-pytest-cov (5.0.0-1) ... Selecting previously unselected package python3-pytest-forked. Preparing to unpack .../094-python3-pytest-forked_1.6.0-2_all.deb ... Unpacking python3-pytest-forked (1.6.0-2) ... Selecting previously unselected package python3-pytest-mock. Preparing to unpack .../095-python3-pytest-mock_3.14.0-2_all.deb ... Unpacking python3-pytest-mock (3.14.0-2) ... Selecting previously unselected package python3-pytest-rerunfailures. Preparing to unpack .../096-python3-pytest-rerunfailures_14.0-2_all.deb ... Unpacking python3-pytest-rerunfailures (14.0-2) ... Selecting previously unselected package python3-pytest-xdist. Preparing to unpack .../097-python3-pytest-xdist_3.6.1-1_all.deb ... Unpacking python3-pytest-xdist (3.6.1-1) ... Selecting previously unselected package python3-urllib3. Preparing to unpack .../098-python3-urllib3_2.2.3-4_all.deb ... Unpacking python3-urllib3 (2.2.3-4) ... Selecting previously unselected package python3-requests. Preparing to unpack .../099-python3-requests_2.32.3+dfsg-1_all.deb ... Unpacking python3-requests (2.32.3+dfsg-1) ... Selecting previously unselected package python3-requests-toolbelt. Preparing to unpack .../100-python3-requests-toolbelt_1.0.0-3_all.deb ... Unpacking python3-requests-toolbelt (1.0.0-3) ... Selecting previously unselected package python3-requests-unixsocket. Preparing to unpack .../101-python3-requests-unixsocket_0.3.0-5_all.deb ... Unpacking python3-requests-unixsocket (0.3.0-5) ... Selecting previously unselected package python3-setuptools-scm. Preparing to unpack .../102-python3-setuptools-scm_8.1.0-1_all.deb ... Unpacking python3-setuptools-scm (8.1.0-1) ... Selecting previously unselected package python3-snowballstemmer. Preparing to unpack .../103-python3-snowballstemmer_2.2.0-4_all.deb ... Unpacking python3-snowballstemmer (2.2.0-4) ... Selecting previously unselected package sphinx-common. Preparing to unpack .../104-sphinx-common_8.1.3-2_all.deb ... Unpacking sphinx-common (8.1.3-2) ... Selecting previously unselected package python3-sphinx. Preparing to unpack .../105-python3-sphinx_8.1.3-2_all.deb ... Unpacking python3-sphinx (8.1.3-2) ... Selecting previously unselected package python3-trustme. Preparing to unpack .../106-python3-trustme_1.2.0-2_all.deb ... Unpacking python3-trustme (1.2.0-2) ... Setting up media-types (10.1.0) ... Setting up libpipeline1:i386 (1.5.8-1) ... Setting up libkeyutils1:i386 (1.6.3-4) ... Setting up libicu72:i386 (72.1-5+b1) ... Setting up bsdextrautils (2.40.2-12) ... Setting up libmagic-mgc (1:5.45-3+b1) ... Setting up libarchive-zip-perl (1.68-1) ... Setting up libtirpc-common (1.3.4+ds-1.3) ... Setting up libdebhelper-perl (13.20) ... Setting up libmagic1t64:i386 (1:5.45-3+b1) ... Setting up gettext-base (0.22.5-2) ... Setting up m4 (1.4.19-4) ... Setting up libcom-err2:i386 (1.47.2~rc1-2) ... Setting up file (1:5.45-3+b1) ... Setting up libjs-jquery-throttle-debounce (1.1+dfsg.1-2) ... Setting up libelf1t64:i386 (0.192-4) ... Setting up python-babel-localedata (2.16.0-1) ... Setting up libkrb5support0:i386 (1.21.3-3) ... Setting up tzdata (2024b-4) ... Current default time zone: 'Etc/UTC' Local time is now: Thu Dec 12 06:46:01 UTC 2024. Universal Time is now: Thu Dec 12 06:46:01 UTC 2024. Run 'dpkg-reconfigure tzdata' if you wish to change it. Setting up libpython3.13-minimal:i386 (3.13.1-1) ... Setting up autotools-dev (20220109.1) ... Setting up autopoint (0.22.5-2) ... Setting up libk5crypto3:i386 (1.21.3-3) ... Setting up autoconf (2.72-3) ... Setting up dwz (0.15-1+b1) ... Setting up sensible-utils (0.0.24) ... Setting up libuchardet0:i386 (0.0.8-1+b2) ... Setting up libjson-perl (4.10000-1) ... Setting up python3.13-minimal (3.13.1-1) ... Setting up netbase (6.4) ... Setting up sgml-base (1.31) ... Setting up libkrb5-3:i386 (1.21.3-3) ... Setting up libjs-jquery (3.6.1+dfsg+~3.5.14-1) ... Setting up libjs-jquery-hotkeys (0~20130707+git2d51e3a9+dfsg-2.1) ... Setting up openssl (3.3.2-2) ... Setting up readline-common (8.2-5) ... Setting up libxml2:i386 (2.12.7+dfsg+really2.9.14-0.2+b1) ... Setting up libjs-underscore (1.13.4~dfsg+~1.11.4-3) ... Setting up automake (1:1.16.5-1.3) ... update-alternatives: using /usr/bin/automake-1.16 to provide /usr/bin/automake (automake) in auto mode Setting up libfile-stripnondeterminism-perl (1.14.0-1) ... Setting up gettext (0.22.5-2) ... Setting up libtool (2.4.7-8) ... Setting up intltool-debian (0.35.0+20060710.6) ... Setting up dh-autoreconf (20) ... Setting up ca-certificates (20240203) ... Updating certificates in /etc/ssl/certs... 146 added, 0 removed; done. Setting up libjs-jquery-metadata (12-4) ... Setting up libjs-jquery-isonscreen (1.2.0-1.1) ... Setting up libgssapi-krb5-2:i386 (1.21.3-3) ... Setting up libjs-sphinxdoc (8.1.3-2) ... Setting up libreadline8t64:i386 (8.2-5) ... Setting up dh-strip-nondeterminism (1.14.0-1) ... Setting up libjs-jquery-tablesorter (1:2.31.3+dfsg1-4) ... Setting up groff-base (1.23.0-6) ... Setting up xml-core (0.19) ... Setting up libpython3.13-stdlib:i386 (3.13.1-1) ... Setting up libtirpc3t64:i386 (1.3.4+ds-1.3+b1) ... Setting up python3.13 (3.13.1-1) ... Setting up po-debconf (1.0.21+nmu1) ... Setting up man-db (2.13.0-1) ... Not building database; man-db/auto-update is not 'true'. Setting up sphinx-common (8.1.3-2) ... Setting up libnsl2:i386 (1.3.0-3+b3) ... Setting up libpython3.12-stdlib:i386 (3.12.8-1) ... Setting up python3.12 (3.12.8-1) ... Setting up debhelper (13.20) ... Setting up libpython3-stdlib:i386 (3.12.7-1) ... Setting up python3 (3.12.7-1) ... Setting up python3-zipp (3.21.0-1) ... Setting up python3-autocommand (2.2.2-3) ... Setting up python3-markupsafe (2.1.5-1+b2) ... Setting up python3-wheel (0.45.1-1) ... Setting up python3-roman (4.2-1) ... Setting up python3-jinja2 (3.1.3-1) ... Setting up python3-packaging (24.2-1) ... Setting up python3-pyproject-hooks (1.2.0-1) ... Setting up python3-certifi (2024.8.30+dfsg-1) ... Setting up python3-snowballstemmer (2.2.0-4) ... Setting up python3-idna (3.8-2) ... Setting up python3-typing-extensions (4.12.2-2) ... Setting up python3-toml (0.10.2-1) ... Setting up python3-installer (0.7.0+dfsg1-3) ... Setting up python3-urllib3 (2.2.3-4) ... Setting up python3-pluggy (1.5.0-1) ... Setting up python3-dateutil (2.9.0-3) ... Setting up python3-build (1.2.2-1) ... Setting up python3-execnet (2.1.1-1) ... Setting up python3-cffi-backend:i386 (1.17.1-2+b1) ... Setting up python3-imagesize (1.4.1-1) ... Setting up python3-more-itertools (10.5.0-1) ... Setting up python3-iniconfig (1.1.1-2) ... Setting up python3-jaraco.functools (4.1.0-1) ... Setting up python3-jaraco.context (6.0.0-1) ... Setting up python3-defusedxml (0.7.1-3) ... Setting up python3-charset-normalizer (3.4.0-1+b1) ... Setting up python3-pytest (8.3.4-1) ... Setting up python3-alabaster (0.7.16-0.1) ... Setting up python3-bcrypt (4.2.0-2.1) ... Setting up python3-typeguard (4.4.1-1) ... Setting up python3-all (3.12.7-1) ... Setting up python3-coverage (7.6.0+dfsg1-2+b1) ... Setting up python3-pytest-cov (5.0.0-1) ... Setting up python3-inflect (7.3.1-2) ... Setting up python3-jaraco.text (4.0.0-1) ... Setting up python3-cryptography (43.0.0-1) ... Setting up python3-pytest-mock (3.14.0-2) ... Setting up python3-tempora (5.7.0-2) ... Setting up python3-pkg-resources (75.2.0-1) ... Setting up python3-pytest-rerunfailures (14.0-2) ... Setting up python3-setuptools (75.2.0-1) ... Setting up python3-pytest-xdist (3.6.1-1) ... Setting up python3-py (1.11.0-2) ... Setting up python3-babel (2.16.0-1) ... update-alternatives: using /usr/bin/pybabel-python3 to provide /usr/bin/pybabel (pybabel) in auto mode Setting up python3-openssl (24.3.0-1) ... Setting up python3-trustme (1.2.0-2) ... Setting up python3-portend (3.2.0-1) ... Setting up python3-setuptools-scm (8.1.0-1) ... Setting up python3-pytest-forked (1.6.0-2) ... Setting up python3-pygments (2.18.0+dfsg-1) ... Setting up python3-chardet (5.2.0+dfsg-1) ... Setting up python3-requests (2.32.3+dfsg-1) ... Setting up dh-python (6.20241024) ... Setting up python3-requests-toolbelt (1.0.0-3) ... Setting up pybuild-plugin-pyproject (6.20241024) ... Setting up python3-requests-unixsocket (0.3.0-5) ... Processing triggers for libc-bin (2.40-4) ... Processing triggers for sgml-base (1.31) ... Setting up docutils-common (0.21.2+dfsg-2) ... Processing triggers for sgml-base (1.31) ... Setting up python3-docutils (0.21.2+dfsg-2) ... Setting up python3-sphinx (8.1.3-2) ... Processing triggers for ca-certificates (20240203) ... 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: user script /srv/workspace/pbuilder/36977/tmp/hooks/A99_set_merged_usr starting Not re-configuring usrmerge for unstable I: user script /srv/workspace/pbuilder/36977/tmp/hooks/A99_set_merged_usr finished hostname: Name or service not known I: Running cd /build/reproducible-path/python-cheroot-10.0.1+ds1/ && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path" HOME="/nonexistent/second-build" dpkg-buildpackage -us -uc -b && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/i/capture/the/path" HOME="/nonexistent/second-build" dpkg-genchanges -S > ../python-cheroot_10.0.1+ds1-2_source.changes dpkg-buildpackage: info: source package python-cheroot dpkg-buildpackage: info: source version 10.0.1+ds1-2 dpkg-buildpackage: info: source distribution unstable dpkg-buildpackage: info: source changed by Colin Watson dpkg-source --before-build . dpkg-buildpackage: info: host architecture i386 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/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot * Building wheel... running bdist_wheel running build running build_py creating build/lib/cheroot copying cheroot/makefile.py -> build/lib/cheroot copying cheroot/_compat.py -> build/lib/cheroot copying cheroot/connections.py -> build/lib/cheroot copying cheroot/wsgi.py -> build/lib/cheroot copying cheroot/__main__.py -> build/lib/cheroot copying cheroot/server.py -> build/lib/cheroot copying cheroot/__init__.py -> build/lib/cheroot copying cheroot/errors.py -> build/lib/cheroot copying cheroot/testing.py -> build/lib/cheroot copying cheroot/cli.py -> build/lib/cheroot creating build/lib/cheroot/test copying cheroot/test/_pytest_plugin.py -> build/lib/cheroot/test copying cheroot/test/test_dispatch.py -> build/lib/cheroot/test copying cheroot/test/conftest.py -> build/lib/cheroot/test copying cheroot/test/helper.py -> build/lib/cheroot/test copying cheroot/test/test_cli.py -> build/lib/cheroot/test copying cheroot/test/test_wsgi.py -> build/lib/cheroot/test copying cheroot/test/test_core.py -> build/lib/cheroot/test copying cheroot/test/test_server.py -> build/lib/cheroot/test copying cheroot/test/test__compat.py -> build/lib/cheroot/test copying cheroot/test/test_conn.py -> build/lib/cheroot/test copying cheroot/test/test_ssl.py -> build/lib/cheroot/test copying cheroot/test/test_makefile.py -> build/lib/cheroot/test copying cheroot/test/__init__.py -> build/lib/cheroot/test copying cheroot/test/test_errors.py -> build/lib/cheroot/test copying cheroot/test/webtest.py -> build/lib/cheroot/test creating build/lib/cheroot/ssl copying cheroot/ssl/builtin.py -> build/lib/cheroot/ssl copying cheroot/ssl/pyopenssl.py -> build/lib/cheroot/ssl copying cheroot/ssl/__init__.py -> build/lib/cheroot/ssl creating build/lib/cheroot/workers copying cheroot/workers/threadpool.py -> build/lib/cheroot/workers copying cheroot/workers/__init__.py -> build/lib/cheroot/workers running egg_info creating cheroot.egg-info writing cheroot.egg-info/PKG-INFO writing dependency_links to cheroot.egg-info/dependency_links.txt writing entry points to cheroot.egg-info/entry_points.txt writing requirements to cheroot.egg-info/requires.txt writing top-level names to cheroot.egg-info/top_level.txt writing manifest file 'cheroot.egg-info/SOURCES.txt' WARNING setuptools_scm._file_finders.git git archive detected - fallback to listing all files adding license file 'LICENSE.md' writing manifest file 'cheroot.egg-info/SOURCES.txt' copying cheroot/__init__.pyi -> build/lib/cheroot copying cheroot/_compat.pyi -> build/lib/cheroot copying cheroot/cli.pyi -> build/lib/cheroot copying cheroot/connections.pyi -> build/lib/cheroot copying cheroot/errors.pyi -> build/lib/cheroot copying cheroot/makefile.pyi -> build/lib/cheroot copying cheroot/py.typed -> build/lib/cheroot copying cheroot/server.pyi -> build/lib/cheroot copying cheroot/testing.pyi -> build/lib/cheroot copying cheroot/wsgi.pyi -> build/lib/cheroot copying cheroot/ssl/__init__.pyi -> build/lib/cheroot/ssl copying cheroot/ssl/builtin.pyi -> build/lib/cheroot/ssl copying cheroot/ssl/pyopenssl.pyi -> build/lib/cheroot/ssl copying cheroot/workers/__init__.pyi -> build/lib/cheroot/workers copying cheroot/workers/threadpool.pyi -> build/lib/cheroot/workers installing to build/bdist.linux-i686/wheel running install running install_lib creating build/bdist.linux-i686/wheel creating build/bdist.linux-i686/wheel/cheroot copying build/lib/cheroot/makefile.py -> build/bdist.linux-i686/wheel/./cheroot creating build/bdist.linux-i686/wheel/cheroot/test copying build/lib/cheroot/test/_pytest_plugin.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_dispatch.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/conftest.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/helper.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_cli.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_wsgi.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_core.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_server.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test__compat.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_conn.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_ssl.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_makefile.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/__init__.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_errors.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/webtest.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/py.typed -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/_compat.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/__init__.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/connections.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/testing.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/_compat.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/cli.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/wsgi.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/server.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/__main__.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/server.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/makefile.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/connections.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/errors.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/__init__.py -> build/bdist.linux-i686/wheel/./cheroot creating build/bdist.linux-i686/wheel/cheroot/ssl copying build/lib/cheroot/ssl/builtin.pyi -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/ssl/__init__.pyi -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/ssl/pyopenssl.pyi -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/ssl/builtin.py -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/ssl/pyopenssl.py -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/ssl/__init__.py -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/errors.py -> build/bdist.linux-i686/wheel/./cheroot creating build/bdist.linux-i686/wheel/cheroot/workers copying build/lib/cheroot/workers/threadpool.py -> build/bdist.linux-i686/wheel/./cheroot/workers copying build/lib/cheroot/workers/__init__.pyi -> build/bdist.linux-i686/wheel/./cheroot/workers copying build/lib/cheroot/workers/threadpool.pyi -> build/bdist.linux-i686/wheel/./cheroot/workers copying build/lib/cheroot/workers/__init__.py -> build/bdist.linux-i686/wheel/./cheroot/workers copying build/lib/cheroot/testing.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/cli.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/wsgi.pyi -> build/bdist.linux-i686/wheel/./cheroot running install_egg_info Copying cheroot.egg-info to build/bdist.linux-i686/wheel/./cheroot-10.0.1+ds1.egg-info running install_scripts creating build/bdist.linux-i686/wheel/cheroot-10.0.1+ds1.dist-info/WHEEL creating '/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/.tmp-xpvl4woh/cheroot-10.0.1+ds1-py3-none-any.whl' and adding 'build/bdist.linux-i686/wheel' to it adding 'cheroot/__init__.py' adding 'cheroot/__init__.pyi' adding 'cheroot/__main__.py' adding 'cheroot/_compat.py' adding 'cheroot/_compat.pyi' adding 'cheroot/cli.py' adding 'cheroot/cli.pyi' adding 'cheroot/connections.py' adding 'cheroot/connections.pyi' adding 'cheroot/errors.py' adding 'cheroot/errors.pyi' adding 'cheroot/makefile.py' adding 'cheroot/makefile.pyi' adding 'cheroot/py.typed' adding 'cheroot/server.py' adding 'cheroot/server.pyi' adding 'cheroot/testing.py' adding 'cheroot/testing.pyi' adding 'cheroot/wsgi.py' adding 'cheroot/wsgi.pyi' adding 'cheroot/ssl/__init__.py' adding 'cheroot/ssl/__init__.pyi' adding 'cheroot/ssl/builtin.py' adding 'cheroot/ssl/builtin.pyi' adding 'cheroot/ssl/pyopenssl.py' adding 'cheroot/ssl/pyopenssl.pyi' adding 'cheroot/test/__init__.py' adding 'cheroot/test/_pytest_plugin.py' adding 'cheroot/test/conftest.py' adding 'cheroot/test/helper.py' adding 'cheroot/test/test__compat.py' adding 'cheroot/test/test_cli.py' adding 'cheroot/test/test_conn.py' adding 'cheroot/test/test_core.py' adding 'cheroot/test/test_dispatch.py' adding 'cheroot/test/test_errors.py' adding 'cheroot/test/test_makefile.py' adding 'cheroot/test/test_server.py' adding 'cheroot/test/test_ssl.py' adding 'cheroot/test/test_wsgi.py' adding 'cheroot/test/webtest.py' adding 'cheroot/workers/__init__.py' adding 'cheroot/workers/__init__.pyi' adding 'cheroot/workers/threadpool.py' adding 'cheroot/workers/threadpool.pyi' adding 'cheroot-10.0.1+ds1.dist-info/LICENSE.md' adding 'cheroot-10.0.1+ds1.dist-info/METADATA' adding 'cheroot-10.0.1+ds1.dist-info/WHEEL' adding 'cheroot-10.0.1+ds1.dist-info/entry_points.txt' adding 'cheroot-10.0.1+ds1.dist-info/top_level.txt' adding 'cheroot-10.0.1+ds1.dist-info/RECORD' removing build/bdist.linux-i686/wheel Successfully built cheroot-10.0.1+ds1-py3-none-any.whl I: pybuild plugin_pyproject:144: Unpacking wheel built for python3.13 with "installer" module I: pybuild plugin_pyproject:129: Building wheel for python3.12 with "build" module I: pybuild base:311: python3.12 -m build --skip-dependency-check --no-isolation --wheel --outdir /build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.12_cheroot * Building wheel... running bdist_wheel running build running build_py running egg_info writing cheroot.egg-info/PKG-INFO writing dependency_links to cheroot.egg-info/dependency_links.txt writing entry points to cheroot.egg-info/entry_points.txt writing requirements to cheroot.egg-info/requires.txt writing top-level names to cheroot.egg-info/top_level.txt WARNING setuptools_scm._file_finders.git git archive detected - fallback to listing all files adding license file 'LICENSE.md' writing manifest file 'cheroot.egg-info/SOURCES.txt' installing to build/bdist.linux-i686/wheel running install running install_lib creating build/bdist.linux-i686/wheel creating build/bdist.linux-i686/wheel/cheroot copying build/lib/cheroot/makefile.py -> build/bdist.linux-i686/wheel/./cheroot creating build/bdist.linux-i686/wheel/cheroot/test copying build/lib/cheroot/test/_pytest_plugin.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_dispatch.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/conftest.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/helper.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_cli.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_wsgi.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_core.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_server.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test__compat.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_conn.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_ssl.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_makefile.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/__init__.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/test_errors.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/test/webtest.py -> build/bdist.linux-i686/wheel/./cheroot/test copying build/lib/cheroot/py.typed -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/_compat.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/__init__.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/connections.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/testing.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/_compat.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/cli.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/wsgi.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/server.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/__main__.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/server.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/makefile.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/connections.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/errors.pyi -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/__init__.py -> build/bdist.linux-i686/wheel/./cheroot creating build/bdist.linux-i686/wheel/cheroot/ssl copying build/lib/cheroot/ssl/builtin.pyi -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/ssl/__init__.pyi -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/ssl/pyopenssl.pyi -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/ssl/builtin.py -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/ssl/pyopenssl.py -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/ssl/__init__.py -> build/bdist.linux-i686/wheel/./cheroot/ssl copying build/lib/cheroot/errors.py -> build/bdist.linux-i686/wheel/./cheroot creating build/bdist.linux-i686/wheel/cheroot/workers copying build/lib/cheroot/workers/threadpool.py -> build/bdist.linux-i686/wheel/./cheroot/workers copying build/lib/cheroot/workers/__init__.pyi -> build/bdist.linux-i686/wheel/./cheroot/workers copying build/lib/cheroot/workers/threadpool.pyi -> build/bdist.linux-i686/wheel/./cheroot/workers copying build/lib/cheroot/workers/__init__.py -> build/bdist.linux-i686/wheel/./cheroot/workers copying build/lib/cheroot/testing.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/cli.py -> build/bdist.linux-i686/wheel/./cheroot copying build/lib/cheroot/wsgi.pyi -> build/bdist.linux-i686/wheel/./cheroot running install_egg_info Copying cheroot.egg-info to build/bdist.linux-i686/wheel/./cheroot-10.0.1+ds1.egg-info running install_scripts creating build/bdist.linux-i686/wheel/cheroot-10.0.1+ds1.dist-info/WHEEL creating '/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.12_cheroot/.tmp-3tmdgqgt/cheroot-10.0.1+ds1-py3-none-any.whl' and adding 'build/bdist.linux-i686/wheel' to it adding 'cheroot/__init__.py' adding 'cheroot/__init__.pyi' adding 'cheroot/__main__.py' adding 'cheroot/_compat.py' adding 'cheroot/_compat.pyi' adding 'cheroot/cli.py' adding 'cheroot/cli.pyi' adding 'cheroot/connections.py' adding 'cheroot/connections.pyi' adding 'cheroot/errors.py' adding 'cheroot/errors.pyi' adding 'cheroot/makefile.py' adding 'cheroot/makefile.pyi' adding 'cheroot/py.typed' adding 'cheroot/server.py' adding 'cheroot/server.pyi' adding 'cheroot/testing.py' adding 'cheroot/testing.pyi' adding 'cheroot/wsgi.py' adding 'cheroot/wsgi.pyi' adding 'cheroot/ssl/__init__.py' adding 'cheroot/ssl/__init__.pyi' adding 'cheroot/ssl/builtin.py' adding 'cheroot/ssl/builtin.pyi' adding 'cheroot/ssl/pyopenssl.py' adding 'cheroot/ssl/pyopenssl.pyi' adding 'cheroot/test/__init__.py' adding 'cheroot/test/_pytest_plugin.py' adding 'cheroot/test/conftest.py' adding 'cheroot/test/helper.py' adding 'cheroot/test/test__compat.py' adding 'cheroot/test/test_cli.py' adding 'cheroot/test/test_conn.py' adding 'cheroot/test/test_core.py' adding 'cheroot/test/test_dispatch.py' adding 'cheroot/test/test_errors.py' adding 'cheroot/test/test_makefile.py' adding 'cheroot/test/test_server.py' adding 'cheroot/test/test_ssl.py' adding 'cheroot/test/test_wsgi.py' adding 'cheroot/test/webtest.py' adding 'cheroot/workers/__init__.py' adding 'cheroot/workers/__init__.pyi' adding 'cheroot/workers/threadpool.py' adding 'cheroot/workers/threadpool.pyi' adding 'cheroot-10.0.1+ds1.dist-info/LICENSE.md' adding 'cheroot-10.0.1+ds1.dist-info/METADATA' adding 'cheroot-10.0.1+ds1.dist-info/WHEEL' adding 'cheroot-10.0.1+ds1.dist-info/entry_points.txt' adding 'cheroot-10.0.1+ds1.dist-info/top_level.txt' adding 'cheroot-10.0.1+ds1.dist-info/RECORD' removing build/bdist.linux-i686/wheel Successfully built cheroot-10.0.1+ds1-py3-none-any.whl I: pybuild plugin_pyproject:144: Unpacking wheel built for python3.12 with "installer" module dh_auto_test -O--buildsystem=pybuild I: pybuild base:311: cd /build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build; python3.13 -m pytest -k "not (test_https_over_http_error)" -n auto --pyargs cheroot.test ============================= test session starts ============================== platform linux -- Python 3.13.1, pytest-8.3.4, pluggy-1.5.0 -- /usr/bin/python3.13 cachedir: .pytest_cache rootdir: /build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build configfile: pytest.ini plugins: typeguard-4.4.1, xdist-3.6.1, cov-5.0.0, forked-1.6.0, rerunfailures-14.0, mock-3.14.0 created: 13/13 workers 13 workers [184 items] scheduling tests via LoadScheduling cheroot/test/test_conn.py::test_HTTP11_persistent_connections cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(EPIPE)] cheroot/test/test_cli.py::test_Aplication_resolve[None-application] cheroot/test/test__compat.py::test_compat_functions_negative_nonnative[ntob] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[foo@bar:5000-expected_bind_addr3] cheroot/test/test__compat.py::test_extract_bytes[qwerty-qwerty] cheroot/test/test_conn.py::test_keepalive[HTTP/1.1] cheroot/test/test__compat.py::test_compat_functions_positive[ntob-bar-bar] [gw2] [ 0%] PASSED cheroot/test/test__compat.py::test_compat_functions_positive[ntob-bar-bar] [gw4] [ 1%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[foo@bar:5000-expected_bind_addr3] [gw1] [ 1%] PASSED cheroot/test/test__compat.py::test_extract_bytes[qwerty-qwerty] [gw0] [ 2%] PASSED cheroot/test/test__compat.py::test_compat_functions_negative_nonnative[ntob] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[ConnectionResetError(ECONNRESET)] [gw7] [ 2%] PASSED cheroot/test/test_cli.py::test_Aplication_resolve[None-application] cheroot/test/test_cli.py::test_Aplication_resolve[application-application] [gw7] [ 3%] PASSED cheroot/test/test_cli.py::test_Aplication_resolve[application-application] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[192.168.1.1:80-expected_bind_addr0] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(ESHUTDOWN)] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[/tmp/cheroot.sock-/tmp/cheroot.sock] [gw6] [ 3%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[/tmp/cheroot.sock-/tmp/cheroot.sock] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[/tmp/some-random-file-name-/tmp/some-random-file-name] [gw6] [ 4%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[/tmp/some-random-file-name-/tmp/some-random-file-name] cheroot/test/test_conn.py::test_streaming_10[False] cheroot/test/test__compat.py::test_compat_functions_positive[ntou-bar-bar] [gw2] [ 4%] PASSED cheroot/test/test__compat.py::test_compat_functions_positive[ntou-bar-bar] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[foo-expected_bind_addr4] [gw4] [ 5%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[foo-expected_bind_addr4] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[@cheroot-\x00cheroot] cheroot/test/test_cli.py::test_Aplication_resolve[main-main] cheroot/test/test__compat.py::test_compat_functions_positive[bton-bar-bar] [gw7] [ 5%] PASSED cheroot/test/test_cli.py::test_Aplication_resolve[main-main] [gw6] [ 6%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[@cheroot-\x00cheroot] [gw2] [ 7%] PASSED cheroot/test/test__compat.py::test_compat_functions_positive[bton-bar-bar] cheroot/test/test_conn.py::test_broken_connection_during_http_communication_fallback cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[123456789-expected_bind_addr5] [gw4] [ 7%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[123456789-expected_bind_addr5] cheroot/test/test_conn.py::test_HTTP11_Timeout[True] cheroot/test/test_conn.py::test_100_Continue cheroot/test/test_conn.py::test_Chunked_Encoding [gw5] [ 8%] PASSED cheroot/test/test_conn.py::test_HTTP11_persistent_connections [gw8] [ 8%] PASSED cheroot/test/test_conn.py::test_keepalive[HTTP/1.1] [gw10] [ 9%] PASSED cheroot/test/test_conn.py::test_streaming_10[False] cheroot/test/test__compat.py::test_compat_functions_negative_nonnative[ntou] cheroot/test/test__compat.py::test_extract_bytes[input_argument1-asdfgh] [gw1] [ 9%] PASSED cheroot/test/test__compat.py::test_extract_bytes[input_argument1-asdfgh] [gw0] [ 10%] PASSED cheroot/test/test__compat.py::test_compat_functions_negative_nonnative[ntou] cheroot/test/test_conn.py::test_streaming_10[True] [gw9] [ 10%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(ESHUTDOWN)] [gw11] [ 11%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(EPIPE)] cheroot/test/test_conn.py::test_streaming_11[False] [gw5] [ 11%] PASSED cheroot/test/test_conn.py::test_streaming_11[False] cheroot/test/test_conn.py::test_keepalive_conn_management [gw3] [ 12%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[192.168.1.1:80-expected_bind_addr0] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[[::1]:8000-expected_bind_addr1] [gw3] [ 13%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[[::1]:8000-expected_bind_addr1] cheroot/test/test__compat.py::test_ntou_escape [gw0] [ 13%] PASSED cheroot/test/test__compat.py::test_ntou_escape cheroot/test/test_conn.py::test_No_CRLF[\r\n\n] cheroot/test/test__compat.py::test_extract_bytes_invalid [gw1] [ 14%] PASSED cheroot/test/test__compat.py::test_extract_bytes_invalid cheroot/test/test_conn.py::test_Content_Length_out[/wrong_cl_unbuffered-200-I too] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[localhost:5000-expected_bind_addr2] [gw3] [ 14%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[localhost:5000-expected_bind_addr2] cheroot/test/test_core.py::test_normal_request [gw10] [ 15%] PASSED cheroot/test/test_conn.py::test_streaming_10[True] [gw12] [ 15%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[ConnectionResetError(ECONNRESET)] [gw2] [ 16%] PASSED cheroot/test/test_conn.py::test_100_Continue cheroot/test/test_conn.py::test_readall_or_close[0] [gw3] [ 16%] PASSED cheroot/test/test_core.py::test_normal_request [gw4] [ 17%] XFAIL cheroot/test/test_conn.py::test_Chunked_Encoding [gw0] [ 17%] PASSED cheroot/test/test_conn.py::test_No_CRLF[\r\n\n] [gw1] [ 18%] PASSED cheroot/test/test_conn.py::test_Content_Length_out[/wrong_cl_unbuffered-200-I too] [gw2] [ 19%] PASSED cheroot/test/test_conn.py::test_readall_or_close[0] cheroot/test/test_conn.py::test_streaming_11[True] [gw5] [ 19%] PASSED cheroot/test/test_conn.py::test_streaming_11[True] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[simulated socket.error(ENOTCONN)] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[BrokenPipeError(EPIPE)] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[RuntimeError(666)] cheroot/test/test_conn.py::test_keepalive[HTTP/1.0] cheroot/test/test_conn.py::test_Content_Length_in cheroot/test/test_core.py::test_query_string_request [gw11] [ 20%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[simulated socket.error(ENOTCONN)] cheroot/test/test_conn.py::test_invalid_selected_connection cheroot/test/test_conn.py::test_598 [gw4] [ 20%] PASSED cheroot/test/test_conn.py::test_Content_Length_in cheroot/test/test_conn.py::test_readall_or_close[1001] [gw9] [ 21%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[RuntimeError(666)] cheroot/test/test_core.py::test_parse_acceptable_uri[/query_string?test=True] [gw12] [ 21%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[BrokenPipeError(EPIPE)] [gw3] [ 22%] PASSED cheroot/test/test_core.py::test_query_string_request [gw5] [ 22%] PASSED cheroot/test/test_core.py::test_parse_acceptable_uri[/query_string?test=True] [gw10] [ 23%] PASSED cheroot/test/test_conn.py::test_keepalive[HTTP/1.0] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[real socket.error(ENOTCONN)] cheroot/test/test_conn.py::test_Content_Length_not_int cheroot/test/test_core.py::test_parse_uri_invalid_uri [gw7] [ 23%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_http_communication_fallback cheroot/test/test_conn.py::test_kb_int_from_http_handler [gw6] [ 24%] PASSED cheroot/test/test_conn.py::test_HTTP11_Timeout[True] cheroot/test/test_conn.py::test_HTTP11_Timeout[False] cheroot/test/test_core.py::test_parse_acceptable_uri[/%D0%AE%D1%85%D1%85%D1%83%D1%83%D1%83?%D1%97=%D0%B9%D0%BE] [gw5] [ 25%] PASSED cheroot/test/test_core.py::test_parse_acceptable_uri[/%D0%AE%D1%85%D1%85%D1%83%D1%83%D1%83?%D1%97=%D0%B9%D0%BE] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[BrokenPipeError(ESHUTDOWN)] cheroot/test/test_core.py::test_parse_acceptable_uri[/hello] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(-1)] [gw0] [ 25%] PASSED cheroot/test/test_conn.py::test_invalid_selected_connection [gw4] [ 26%] PASSED cheroot/test/test_conn.py::test_Content_Length_not_int [gw3] [ 26%] PASSED cheroot/test/test_core.py::test_parse_acceptable_uri[/hello] cheroot/test/test_core.py::test_http_connect_request [gw10] [ 27%] PASSED cheroot/test/test_core.py::test_parse_uri_invalid_uri [gw12] [ 27%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[BrokenPipeError(ESHUTDOWN)] [gw2] [ 28%] PASSED cheroot/test/test_conn.py::test_readall_or_close[1001] cheroot/test/test_conn.py::test_No_Message_Body cheroot/test/test_core.py::test_parse_uri_unsafe_uri [gw9] [ 28%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(-1)] [gw0] [ 29%] PASSED cheroot/test/test_core.py::test_http_connect_request cheroot/test/test_core.py::test_parse_no_leading_slash_invalid[hello] [gw2] [ 29%] PASSED cheroot/test/test_conn.py::test_No_Message_Body [gw7] [ 30%] PASSED cheroot/test/test_conn.py::test_kb_int_from_http_handler cheroot/test/test_conn.py::test_unhandled_exception_in_request_handler cheroot/test/test_core.py::test_send_header_before_closing [gw2] [ 30%] PASSED cheroot/test/test_core.py::test_send_header_before_closing [gw11] [ 31%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[real socket.error(ENOTCONN)] cheroot/test/test_core.py::test_malformed_request_line[GET / HTTP/2.15-505-Cannot fulfill request] [gw5] [ 32%] PASSED cheroot/test/test_core.py::test_parse_uri_unsafe_uri cheroot/test/test_core.py::test_malformed_request_line[GET /-400-Malformed Request-Line] cheroot/test/test_conn.py::test_Content_Length_out[/wrong_cl_buffered-500-The requested resource returned more bytes than the declared Content-Length.] [gw10] [ 32%] PASSED cheroot/test/test_core.py::test_parse_no_leading_slash_invalid[hello] cheroot/test/test_errors.py::test_plat_specific_errors[err_names0-err_nums0] [gw5] [ 33%] PASSED cheroot/test/test_errors.py::test_plat_specific_errors[err_names0-err_nums0] cheroot/test/test_errors.py::test_plat_specific_errors[err_names1-err_nums1] [gw5] [ 33%] PASSED cheroot/test/test_errors.py::test_plat_specific_errors[err_names1-err_nums1] cheroot/test/test_server.py::test_prepare_makes_server_ready [gw4] [ 34%] PASSED cheroot/test/test_conn.py::test_Content_Length_out[/wrong_cl_buffered-500-The requested resource returned more bytes than the declared Content-Length.] cheroot/test/test_core.py::test_no_content_length [gw5] [ 34%] PASSED cheroot/test/test_server.py::test_prepare_makes_server_ready cheroot/test/test_server.py::test_stop_interrupts_serve cheroot/test/test_core.py::test_request_line_split_issue_1220 [gw9] [ 35%] PASSED cheroot/test/test_core.py::test_no_content_length cheroot/test/test_core.py::test_parse_uri_absolute_uri [gw0] [ 35%] PASSED cheroot/test/test_core.py::test_request_line_split_issue_1220 cheroot/test/test_dispatch.py::test_dispatch_no_script_name [gw2] [ 36%] PASSED cheroot/test/test_dispatch.py::test_dispatch_no_script_name cheroot/test/test_server.py::test_server_interrupt[OSError1] [gw11] [ 36%] PASSED cheroot/test/test_core.py::test_parse_uri_absolute_uri [gw1] [ 37%] XFAIL cheroot/test/test_conn.py::test_598 cheroot/test/test_core.py::test_parse_no_leading_slash_invalid[\u043f\u0440\u0438\u0432\u0456\u0442] [gw12] [ 38%] PASSED cheroot/test/test_core.py::test_malformed_request_line[GET / HTTP/2.15-505-Cannot fulfill request] cheroot/test/test_makefile.py::test_bytes_read [gw10] [ 38%] PASSED cheroot/test/test_core.py::test_parse_no_leading_slash_invalid[\u043f\u0440\u0438\u0432\u0456\u0442] [gw4] [ 39%] PASSED cheroot/test/test_makefile.py::test_bytes_read cheroot/test/test_makefile.py::test_bytes_written [gw4] [ 39%] PASSED cheroot/test/test_makefile.py::test_bytes_written cheroot/test/test_server.py::test_bind_addr_inet[::] [gw3] [ 40%] PASSED cheroot/test/test_core.py::test_malformed_request_line[GET /-400-Malformed Request-Line] cheroot/test/test_core.py::test_content_length_required [gw4] [ 40%] PASSED cheroot/test/test_server.py::test_bind_addr_inet[::] cheroot/test/test_core.py::test_garbage_in [gw9] [ 41%] PASSED cheroot/test/test_core.py::test_content_length_required cheroot/test/test_core.py::test_large_request cheroot/test/test_conn.py::test_No_CRLF[\n\n] cheroot/test/test_core.py::test_parse_uri_asterisk_uri [gw5] [ 41%] PASSED cheroot/test/test_server.py::test_stop_interrupts_serve cheroot/test/test_server.py::test_server_interrupt[OSError0] cheroot/test/test_core.py::test_malformed_request_line[GET / HTTPS/1.1-400-Malformed Request-Line: bad protocol] cheroot/test/test_core.py::test_malformed_http_method [gw8] [ 42%] PASSED cheroot/test/test_conn.py::test_keepalive_conn_management [gw0] [ 42%] PASSED cheroot/test/test_core.py::test_garbage_in cheroot/test/test_server.py::test_serving_is_false_and_stop_returns_after_ctrlc cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(ECONNRESET)] [gw1] [ 43%] PASSED cheroot/test/test_conn.py::test_No_CRLF[\n\n] [gw11] [ 44%] PASSED cheroot/test/test_core.py::test_parse_uri_asterisk_uri cheroot/test/test_server.py::test_bind_addr_unix[abstract] [gw7] [ 44%] PASSED cheroot/test/test_conn.py::test_unhandled_exception_in_request_handler [gw2] [ 45%] PASSED cheroot/test/test_server.py::test_server_interrupt[OSError1] [gw10] [ 45%] PASSED cheroot/test/test_server.py::test_serving_is_false_and_stop_returns_after_ctrlc cheroot/test/test_conn.py::test_remains_alive_post_unhandled_exception cheroot/test/test_server.py::test_server_interrupt[RuntimeError] cheroot/test/test_server.py::test_bind_addr_inet[0.0.0.0] [gw3] [ 46%] PASSED cheroot/test/test_core.py::test_malformed_request_line[GET / HTTPS/1.1-400-Malformed Request-Line: bad protocol] [gw4] [ 46%] PASSED cheroot/test/test_server.py::test_bind_addr_unix[abstract] [gw12] [ 47%] PASSED cheroot/test/test_core.py::test_malformed_http_method [gw10] [ 47%] PASSED cheroot/test/test_server.py::test_bind_addr_inet[0.0.0.0] [gw8] [ 48%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(ECONNRESET)] cheroot/test/test_server.py::test_bind_addr_unix[file] cheroot/test/test_core.py::test_parse_uri_fragment_uri cheroot/test/test_server.py::test_peercreds_unix_sock_with_lookup[abstract] [gw6] [ 48%] PASSED cheroot/test/test_conn.py::test_HTTP11_Timeout[False] [gw0] [ 49%] PASSED cheroot/test/test_server.py::test_bind_addr_unix[file] cheroot/test/test_conn.py::test_HTTP11_Timeout_after_request [gw11] [ 50%] PASSED cheroot/test/test_core.py::test_parse_uri_fragment_uri cheroot/test/test_core.py::test_malformed_request_line[GET / HTTP/1-400-Malformed Request-Line: bad version] cheroot/test/test_server.py::test_reuse_port[0.0.0.0] cheroot/test/test_server.py::test_threadpool_threadrange_set[1--1-inf] [gw10] [ 50%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[1--1-inf] cheroot/test/test_core.py::test_malformed_header [gw1] [ 51%] PASSED cheroot/test/test_server.py::test_peercreds_unix_sock_with_lookup[abstract] cheroot/test/test_server.py::test_threadpool_threadrange_set[2--2-inf] cheroot/test/test_server.py::test_high_number_of_file_descriptors[1024] [gw10] [ 51%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[2--2-inf] cheroot/test/test_server.py::test_peercreds_unix_sock_with_lookup[file] cheroot/test/test_server.py::test_threadpool_threadrange_set[2-2-2] [gw10] [ 52%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[2-2-2] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1--1-min=-1 must be > 0] [gw2] [ 52%] PASSED cheroot/test/test_server.py::test_server_interrupt[RuntimeError] [gw10] [ 53%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1--1-min=-1 must be > 0] cheroot/test/test_server.py::test_threadpool_threadrange_set[1--2-inf] [gw2] [ 53%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[1--2-inf] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-1-min=-1 must be > 0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-0-min=-1 must be > 0] [gw10] [ 54%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-0-min=-1 must be > 0] [gw7] [ 54%] PASSED cheroot/test/test_conn.py::test_remains_alive_post_unhandled_exception [gw2] [ 55%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-1-min=-1 must be > 0] [gw4] [ 55%] PASSED cheroot/test/test_server.py::test_reuse_port[0.0.0.0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-2-min=-1 must be > 0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0--1-min=0 must be > 0] [gw2] [ 56%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0--1-min=0 must be > 0] [gw10] [ 57%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-2-min=-1 must be > 0] [gw5] [ 57%] PASSED cheroot/test/test_server.py::test_server_interrupt[OSError0] cheroot/test/test_server.py::test_threadpool_threadrange_set[1-inf-inf] [gw4] [ 58%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[1-inf-inf] cheroot/test/test_server.py::test_reuse_port[::] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-1-min=0 must be > 0] [gw2] [ 58%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-1-min=0 must be > 0] cheroot/test/test_server.py::test_server_interrupt[KeyboardInterrupt] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-0-min=0 must be > 0] [gw7] [ 59%] PASSED cheroot/test/test_server.py::test_reuse_port[::] [gw1] [ 59%] PASSED cheroot/test/test_server.py::test_peercreds_unix_sock_with_lookup[file] [gw10] [ 60%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-0-min=0 must be > 0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[1-0.5-Expected an integer or the infinity value for the `max` argument but got 0.5.] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-2-min=0 must be > 0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-0-Expected an integer or the infinity value for the `max` argument but got 0.] cheroot/test/test_server.py::test_bind_addr_unix_abstract cheroot/test/test_server.py::test_threadpool_invalid_threadrange[1-0-Expected an integer or the infinity value for the `max` argument but got 0.] cheroot/test/test_server.py::test_threadpool_threadrange_set[1-1-1] [gw7] [ 60%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-2-min=0 must be > 0] [gw11] [ 61%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[1-1-1] [gw4] [ 61%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[1-0-Expected an integer or the infinity value for the `max` argument but got 0.] [gw10] [ 62%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-0-Expected an integer or the infinity value for the `max` argument but got 0.] [gw2] [ 63%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[1-0.5-Expected an integer or the infinity value for the `max` argument but got 0.5.] [gw9] [ 63%] XFAIL cheroot/test/test_core.py::test_large_request cheroot/test/test_server.py::test_peercreds_unix_sock[abstract] cheroot/test/test_ssl.py::test_ssl_adapters[pyopenssl] cheroot/test/test_ssl.py::test_ssl_adapters[builtin] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-1-max=1 must be > min=2] cheroot/test/test_server.py::test_threadpool_multistart_validation cheroot/test/test_ssl.py::test_tls_client_auth[0-True-localhost-builtin] [gw2] [ 64%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-1-max=1 must be > min=2] [gw7] [ 64%] PASSED cheroot/test/test_server.py::test_threadpool_multistart_validation cheroot/test/test_ssl.py::test_tls_client_auth[0-True-*.localhost-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-*.localhost-builtin] [gw3] [ 65%] PASSED cheroot/test/test_core.py::test_malformed_request_line[GET / HTTP/1-400-Malformed Request-Line: bad version] cheroot/test/test_server.py::test_threadpool_threadrange_set[2-inf-inf] [gw1] [ 65%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[2-inf-inf] [gw9] [ 66%] PASSED cheroot/test/test_server.py::test_peercreds_unix_sock[abstract] cheroot/test/test_ssl.py::test_tls_client_auth[0-False-localhost-pyopenssl] cheroot/test/test_server.py::test_peercreds_unix_sock[file] [gw0] [ 66%] PASSED cheroot/test/test_server.py::test_bind_addr_unix_abstract [gw7] [ 67%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-*.localhost-builtin] [gw9] [ 67%] PASSED cheroot/test/test_server.py::test_peercreds_unix_sock[file] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-localhost-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[0-False-localhost-builtin] [gw11] [ 68%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-localhost-builtin] [gw8] [ 69%] PASSED cheroot/test/test_server.py::test_high_number_of_file_descriptors[1024] [gw12] [ 69%] PASSED cheroot/test/test_core.py::test_malformed_header [gw10] [ 70%] PASSED cheroot/test/test_ssl.py::test_ssl_adapters[pyopenssl] [gw7] [ 70%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-False-localhost-builtin] cheroot/test/test_server.py::test_threadpool_threadrange_set[1-2-2] cheroot/test/test_server.py::test_threadpool_threadrange_set[2--1-inf] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-localhost-pyopenssl] [gw3] [ 71%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[1-2-2] cheroot/test/test_server.py::test_high_number_of_file_descriptors[2048] [gw12] [ 71%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[2--1-inf] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-*.localhost-builtin] SysCallError(32, 'EPIPE') cheroot/test/test_ssl.py::test_tls_client_auth[1-True-not_localhost-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-not_localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-127.0.0.1-pyopenssl] Client ('127.0.0.1', 43346) lost — peer dropped the TLS connection suddenly, during handshake: (8, '[SSL: UNEXPECTED_EOF_WHILE_READING] EOF occurred in violation of protocol (_ssl.c:1018)') cheroot/test/test_ssl.py::test_tls_client_auth[0-True-127.0.0.1-pyopenssl] [gw5] [ 72%] PASSED cheroot/test/test_server.py::test_server_interrupt[KeyboardInterrupt] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-1-Expected an integer or the infinity value for the `max` argument but got '1'.] [gw5] [ 72%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-1-Expected an integer or the infinity value for the `max` argument but got '1'.] [gw7] [ 73%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-127.0.0.1-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-127.0.0.1-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-localhost-pyopenssl] Traceback (most recent call last): File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/server.py", line 1291, in communicate req.respond() ~~~~~~~~~~~^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/server.py", line 1081, in respond self.server.gateway(self).respond() ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/test/test_ssl.py", line 76, in respond req.ensure_headers_sent() ~~~~~~~~~~~~~~~~~~~~~~~^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/server.py", line 1128, in ensure_headers_sent self.send_headers() ~~~~~~~~~~~~~~~~~^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/server.py", line 1228, in send_headers self.conn.wfile.write(EMPTY.join(buf)) ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/makefile.py", line 68, in write res = super().write(val, *args, **kwargs) File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/makefile.py", line 24, in write self._flush_unlocked() ~~~~~~~~~~~~~~~~~~~~^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/makefile.py", line 33, in _flush_unlocked n = self.raw.write(bytes(self._write_buf)) File "/usr/lib/python3.13/socket.py", line 737, in write return self._sock.send(b) ~~~~~~~~~~~~~~~^^^ File "/usr/lib/python3/dist-packages/OpenSSL/SSL.py", line 2182, in send self._raise_ssl_error(self._ssl, result) ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/OpenSSL/SSL.py", line 1962, in _raise_ssl_error raise SysCallError(errno, errorcode.get(errno)) OpenSSL.SSL.SysCallError: (32, 'EPIPE') [gw8] [ 73%] PASSED cheroot/test/test_server.py::test_high_number_of_file_descriptors[2048] SysCallError(32, 'EPIPE') [gw0] [ 74%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-localhost-pyopenssl] [gw7] [ 75%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-localhost-pyopenssl] [gw3] [ 75%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-*.localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-not_localhost-builtin] Traceback (most recent call last): File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/server.py", line 1291, in communicate req.respond() ~~~~~~~~~~~^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/server.py", line 1081, in respond self.server.gateway(self).respond() ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/test/test_ssl.py", line 77, in respond req.write(b'Hello world!') ~~~~~~~~~^^^^^^^^^^^^^^^^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/server.py", line 1135, in write self.conn.wfile.write(EMPTY.join(buf)) ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/makefile.py", line 68, in write res = super().write(val, *args, **kwargs) File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/makefile.py", line 24, in write self._flush_unlocked() ~~~~~~~~~~~~~~~~~~~~^^ File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/makefile.py", line 33, in _flush_unlocked n = self.raw.write(bytes(self._write_buf)) File "/usr/lib/python3.13/socket.py", line 737, in write return self._sock.send(b) ~~~~~~~~~~~~~~~^^^ File "/usr/lib/python3/dist-packages/OpenSSL/SSL.py", line 2182, in send self._raise_ssl_error(self._ssl, result) ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^ File "/usr/lib/python3/dist-packages/OpenSSL/SSL.py", line 1962, in _raise_ssl_error raise SysCallError(errno, errorcode.get(errno)) OpenSSL.SSL.SysCallError: (32, 'EPIPE') cheroot/test/test_ssl.py::test_tls_client_auth[2-True-*.localhost-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[1-False-localhost-builtin] [gw6] [ 76%] PASSED cheroot/test/test_conn.py::test_HTTP11_Timeout_after_request [gw7] [ 76%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-*.localhost-pyopenssl] cheroot/test/test_conn.py::test_HTTP11_pipelining cheroot/test/test_ssl.py::test_tls_client_auth[2-True-not_localhost-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-*.localhost-pyopenssl] [gw3] [ 77%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-False-localhost-builtin] [gw6] [ 77%] PASSED cheroot/test/test_conn.py::test_HTTP11_pipelining cheroot/test/test_ssl.py::test_tls_client_auth[2-False-localhost-pyopenssl] [gw5] [ 78%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-127.0.0.1-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[2-False-localhost-builtin] [gw0] [ 78%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-not_localhost-builtin] [gw7] [ 79%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-not_localhost-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-not_localhost-builtin] [gw8] [ 79%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-*.localhost-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[0-False-builtin] [gw6] [ 80%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-False-localhost-pyopenssl] [gw0] [ 80%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-not_localhost-builtin] [gw3] [ 81%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-False-localhost-builtin] [gw7] [ 82%] PASSED cheroot/test/test_ssl.py::test_ssl_env[0-False-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-*.localhost-builtin] [gw4] [ 82%] FAILED cheroot/test/test_ssl.py::test_ssl_adapters[builtin] cheroot/test/test_ssl.py::test_ssl_env[1-False-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[0-False-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[0-True-builtin] [gw7] [ 83%] PASSED cheroot/test/test_ssl.py::test_ssl_env[1-False-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[1-False-builtin] [gw8] [ 83%] PASSED cheroot/test/test_ssl.py::test_ssl_env[0-False-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-127.0.0.1-builtin] cheroot/test/test_ssl.py::test_ssl_env[0-True-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[2-True-builtin] [gw5] [ 84%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-*.localhost-builtin] [gw2] [ 84%] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-*.localhost-pyopenssl] [gw6] [ 85%] PASSED cheroot/test/test_ssl.py::test_ssl_env[0-True-builtin] cheroot/test/test_ssl.py::test_ssl_env[2-True-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[1-True-pyopenssl] [gw3] [ 85%] PASSED cheroot/test/test_ssl.py::test_ssl_env[0-True-pyopenssl] [gw4] [ 86%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-127.0.0.1-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-not_localhost-pyopenssl] [gw1] [ 86%] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[0-False-localhost-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[1-True-builtin] [gw2] [ 87%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-not_localhost-pyopenssl] [gw6] [ 88%] PASSED cheroot/test/test_ssl.py::test_ssl_env[2-True-pyopenssl] [gw7] [ 88%] PASSED cheroot/test/test_ssl.py::test_ssl_env[1-True-pyopenssl] [gw11] [ 89%] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-not_localhost-builtin] [gw12] [ 89%] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-not_localhost-pyopenssl] cheroot/test/test_wsgi.py::test_gateway_start_response_called_twice [gw7] [ 90%] PASSED cheroot/test/test_wsgi.py::test_gateway_start_response_called_twice [gw5] [ 90%] PASSED cheroot/test/test_ssl.py::test_ssl_env[1-True-builtin] cheroot/test/test_wsgi.py::test_connection_keepalive [gw9] [ 91%] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-localhost-pyopenssl] [gw10] [ 91%] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-127.0.0.1-pyopenssl] [gw8] [ 92%] PASSED cheroot/test/test_ssl.py::test_ssl_env[2-True-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-localhost-builtin] cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-pyopenssl] cheroot/test/test_ssl.py::test_http_over_https_error[::-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-127.0.0.1-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[1-False-localhost-pyopenssl] cheroot/test/webtest.py::cheroot.test.webtest.WebCase.getPage cheroot/test/test_ssl.py::test_tls_client_auth[1-True-localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-127.0.0.1-builtin] cheroot/test/test_wsgi.py::test_gateway_write_needs_start_response_called_before cheroot/test/test_ssl.py::test_http_over_https_error[::-pyopenssl] [gw2] [ 92%] PASSED cheroot/test/test_wsgi.py::test_gateway_write_needs_start_response_called_before [gw5] [ 93%] PASSED cheroot/test/webtest.py::cheroot.test.webtest.WebCase.getPage [gw12] [ 94%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-False-localhost-pyopenssl] [gw11] [ 94%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-localhost-builtin] [gw1] [ 95%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-localhost-builtin] [gw10] [ 95%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-127.0.0.1-builtin] [gw3] [ 96%] PASSED cheroot/test/test_ssl.py::test_http_over_https_error[::-builtin] [gw8] [ 96%] PASSED cheroot/test/test_ssl.py::test_http_over_https_error[::-pyopenssl] [gw9] [ 97%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-127.0.0.1-builtin] [gw0] [ 97%] FAILED cheroot/test/test_ssl.py::test_ssl_env[1-False-builtin] cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-builtin] [gw0] [ 98%] PASSED cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-builtin] [gw4] [ 98%] RERUN cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-pyopenssl] cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-pyopenssl] [gw4] [ 98%] RERUN cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-pyopenssl] cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-pyopenssl] [gw4] [ 98%] PASSED cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-pyopenssl] [gw6] [ 99%] PASSED cheroot/test/test_wsgi.py::test_connection_keepalive cheroot/test/webtest.py::cheroot.test.webtest.strip_netloc [gw6] [100%] PASSED cheroot/test/webtest.py::cheroot.test.webtest.strip_netloc Exception ignored in: Traceback (most recent call last): File "/usr/lib/python3.13/_pyio.py", line 418, in __del__ self.close() File "/usr/lib/python3.13/_pyio.py", line 1313, in close self.flush() File "/usr/lib/python3.13/_pyio.py", line 1274, in flush self._flush_unlocked() File "/build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/cheroot/makefile.py", line 33, in _flush_unlocked n = self.raw.write(bytes(self._write_buf)) File "/usr/lib/python3.13/socket.py", line 737, in write return self._sock.send(b) File "/usr/lib/python3.13/ssl.py", line 1234, in send return super().send(data, flags) OSError: [Errno 9] Bad file descriptor =================================== FAILURES =================================== __________________________ test_ssl_adapters[builtin] __________________________ [gw4] linux -- Python 3.13.1 /usr/bin/python3.13 self = conn = , method = 'GET' url = '/', body = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) timeout = Timeout(connect=0.1, read=0.1, total=None), chunked = False response_conn = preload_content = False, decode_content = False, enforce_content_length = True def _make_request( self, conn: BaseHTTPConnection, method: str, url: str, body: _TYPE_BODY | None = None, headers: typing.Mapping[str, str] | None = None, retries: Retry | None = None, timeout: _TYPE_TIMEOUT = _DEFAULT_TIMEOUT, chunked: bool = False, response_conn: BaseHTTPConnection | None = None, preload_content: bool = True, decode_content: bool = True, enforce_content_length: bool = True, ) -> BaseHTTPResponse: """ Perform a request on a given urllib connection object taken from our pool. :param conn: a connection from one of our connection pools :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param response_conn: Set this to ``None`` if you will handle releasing the connection or set the connection to have the response release it. :param preload_content: If True, the response's body will be preloaded during construction. :param decode_content: If True, will attempt to decode the body based on the 'content-encoding' header. :param enforce_content_length: Enforce content length checking. Body returned by server must match value of Content-Length header, if present. Otherwise, raise error. """ self.num_requests += 1 timeout_obj = self._get_timeout(timeout) timeout_obj.start_connect() conn.timeout = Timeout.resolve_default_timeout(timeout_obj.connect_timeout) try: # Trigger any extra validation we need to do. try: > self._validate_conn(conn) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=42123): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:466: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:1095: in _validate_conn conn.connect() __class__ = conn = self = /usr/lib/python3/dist-packages/urllib3/connection.py:730: in connect sock_and_verified = _ssl_wrap_socket_and_match_hostname( is_time_off = False probe_http2_host = '127.0.0.1' probe_http2_port = 42123 self = server_hostname = '127.0.0.1' server_hostname_rm_dot = '127.0.0.1' sock = target_supports_http2 = False tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/connection.py:909: in _ssl_wrap_socket_and_match_hostname ssl_sock = ssl_wrap_socket( assert_fingerprint = None assert_hostname = None ca_cert_data = None ca_cert_dir = None ca_certs = '/tmp/tmphqb4lbaq.pem' cert_file = None cert_reqs = 'CERT_REQUIRED' context = default_ssl_context = True key_file = None key_password = None normalized = '127.0.0.1' server_hostname = '127.0.0.1' sock = ssl_context = None ssl_maximum_version = None ssl_minimum_version = None ssl_version = None tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/util/ssl_.py:469: in ssl_wrap_socket ssl_sock = _ssl_wrap_socket_impl(sock, context, tls_in_tls, server_hostname) ca_cert_data = None ca_cert_dir = None ca_certs = '/tmp/tmphqb4lbaq.pem' cert_reqs = None certfile = None ciphers = None context = key_password = None keyfile = None server_hostname = '127.0.0.1' sock = ssl_context = ssl_version = None tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/util/ssl_.py:513: in _ssl_wrap_socket_impl return ssl_context.wrap_socket(sock, server_hostname=server_hostname) server_hostname = '127.0.0.1' sock = ssl_context = tls_in_tls = False /usr/lib/python3.13/ssl.py:455: in wrap_socket return self.sslsocket_class._create( do_handshake_on_connect = True self = server_hostname = '127.0.0.1' server_side = False session = None sock = suppress_ragged_eofs = True /usr/lib/python3.13/ssl.py:1076: in _create self.do_handshake() __class__ = cls = connected = True context = do_handshake_on_connect = True kwargs = {'family': , 'fileno': 18, 'proto': 6, 'type': } self = server_hostname = '127.0.0.1' server_side = False session = None sock = sock_timeout = 0.1 suppress_ragged_eofs = True timeout = 0.1 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , block = False @_sslcopydoc def do_handshake(self, block=False): self._check_connected() timeout = self.gettimeout() try: if timeout == 0.0 and block: self.settimeout(None) > self._sslobj.do_handshake() E TimeoutError: _ssl.c:1001: The handshake operation timed out block = False self = timeout = 0.1 /usr/lib/python3.13/ssl.py:1372: TimeoutError The above exception was the direct cause of the following exception: self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmphqb4lbaq.pem', cert = None proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: > resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) cert = None chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmphqb4lbaq.pem' /usr/lib/python3/dist-packages/requests/adapters.py:667: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:843: in urlopen retries = retries.increment( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=42123): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/util/retry.py:474: in increment raise reraise(type(error), error, _stacktrace) _pool = _stacktrace = cause = 'unknown' connect = None error = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=42123): Read timed out. (read timeout=0.1)") method = 'GET' other = None read = False redirect = None redirect_location = None response = None self = Retry(total=0, connect=None, read=False, redirect=None, status=None) status = None status_count = None total = -1 url = '/' /usr/lib/python3/dist-packages/urllib3/util/util.py:39: in reraise raise value tb = None tp = value = None /usr/lib/python3/dist-packages/urllib3/connectionpool.py:789: in urlopen response = self._make_request( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=42123): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:490: in _make_request raise new_e body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=42123): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:468: in _make_request self._raise_timeout(err=e, url=url, timeout_value=conn.timeout) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=42123): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = err = TimeoutError('_ssl.c:1001: The handshake operation timed out'), url = '/' timeout_value = 0.1 def _raise_timeout( self, err: BaseSSLError | OSError | SocketTimeout, url: str, timeout_value: _TYPE_TIMEOUT | None, ) -> None: """Is the error actually a timeout? Will raise a ReadTimeout or pass""" if isinstance(err, SocketTimeout): > raise ReadTimeoutError( self, url, f"Read timed out. (read timeout={timeout_value})" ) from err E urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='127.0.0.1', port=42123): Read timed out. (read timeout=0.1) err = TimeoutError('_ssl.c:1001: The handshake operation timed out') self = timeout_value = 0.1 url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:369: ReadTimeoutError During handling of the above exception, another exception occurred: http_request_timeout = 0.1 tls_http_server = functools.partial(, request=>) adapter_type = 'builtin' tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmp6nsq8ib9.pem' tls_certificate_private_key_pem_path = '/tmp/tmpy_rsl_s5.pem' tls_ca_certificate_pem_path = '/tmp/tmphqb4lbaq.pem' @pytest.mark.parametrize( 'adapter_type', ( 'builtin', 'pyopenssl', ), ) def test_ssl_adapters( http_request_timeout, tls_http_server, adapter_type, tls_certificate, tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, tls_ca_certificate_pem_path, ): """Test ability to connect to server via HTTPS using adapters.""" interface, _host, port = _get_conn_data(ANY_INTERFACE_IPV4) tls_adapter_cls = get_ssl_adapter_class(name=adapter_type) tls_adapter = tls_adapter_cls( tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, ) if adapter_type == 'pyopenssl': tls_adapter.context = tls_adapter.get_context() tls_certificate.configure_cert(tls_adapter.context) tlshttpserver = tls_http_server((interface, port), tls_adapter) # testclient = get_server_client(tlshttpserver) # testclient.get('/') interface, _host, port = _get_conn_data( tlshttpserver.bind_addr, ) > resp = requests.get( 'https://{host!s}:{port!s}/'.format(host=interface, port=port), timeout=http_request_timeout, verify=tls_ca_certificate_pem_path, ) _host = '127.0.0.1' adapter_type = 'builtin' http_request_timeout = 0.1 interface = '127.0.0.1' port = 42123 tls_adapter = tls_adapter_cls = tls_ca_certificate_pem_path = '/tmp/tmphqb4lbaq.pem' tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmp6nsq8ib9.pem' tls_certificate_private_key_pem_path = '/tmp/tmpy_rsl_s5.pem' tls_http_server = functools.partial(, request=>) tlshttpserver = cheroot/test/test_ssl.py:223: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/requests/api.py:73: in get return request("get", url, params=params, **kwargs) kwargs = {'timeout': 0.1, 'verify': '/tmp/tmphqb4lbaq.pem'} params = None url = 'https://127.0.0.1:42123/' /usr/lib/python3/dist-packages/requests/api.py:59: in request return session.request(method=method, url=url, **kwargs) kwargs = {'params': None, 'timeout': 0.1, 'verify': '/tmp/tmphqb4lbaq.pem'} method = 'get' session = url = 'https://127.0.0.1:42123/' /usr/lib/python3/dist-packages/requests/sessions.py:589: in request resp = self.send(prep, **send_kwargs) allow_redirects = True auth = None cert = None cookies = None data = None files = None headers = None hooks = None json = None method = 'get' params = None prep = proxies = {'no': 'localhost'} req = self = send_kwargs = {'allow_redirects': True, 'cert': None, 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, ...} settings = {'cert': None, 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'verify': '/tmp/tmphqb4lbaq.pem'} stream = None timeout = 0.1 url = 'https://127.0.0.1:42123/' verify = '/tmp/tmphqb4lbaq.pem' /usr/lib/python3/dist-packages/requests/sessions.py:703: in send r = adapter.send(request, **kwargs) adapter = allow_redirects = True hooks = {'response': []} kwargs = {'cert': None, 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'timeout': 0.1, ...} request = self = start = 1733986034.7170348 stream = False _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmphqb4lbaq.pem', cert = None proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) except (ProtocolError, OSError) as err: raise ConnectionError(err, request=request) except MaxRetryError as e: if isinstance(e.reason, ConnectTimeoutError): # TODO: Remove this in 3.0.0: see #2811 if not isinstance(e.reason, NewConnectionError): raise ConnectTimeout(e, request=request) if isinstance(e.reason, ResponseError): raise RetryError(e, request=request) if isinstance(e.reason, _ProxyError): raise ProxyError(e, request=request) if isinstance(e.reason, _SSLError): # This branch is for urllib3 v1.22 and later. raise SSLError(e, request=request) raise ConnectionError(e, request=request) except ClosedPoolError as e: raise ConnectionError(e, request=request) except _ProxyError as e: raise ProxyError(e) except (_SSLError, _HTTPError) as e: if isinstance(e, _SSLError): # This branch is for urllib3 versions earlier than v1.22 raise SSLError(e, request=request) elif isinstance(e, ReadTimeoutError): > raise ReadTimeout(e, request=request) E requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='127.0.0.1', port=42123): Read timed out. (read timeout=0.1) cert = None chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmphqb4lbaq.pem' /usr/lib/python3/dist-packages/requests/adapters.py:713: ReadTimeout ______________ test_tls_client_auth[0-True-*.localhost-pyopenssl] ______________ [gw2] linux -- Python 3.13.1 /usr/bin/python3.13 self = conn = , method = 'GET' url = '/', body = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) timeout = Timeout(connect=0.1, read=0.1, total=None), chunked = False response_conn = preload_content = False, decode_content = False, enforce_content_length = True def _make_request( self, conn: BaseHTTPConnection, method: str, url: str, body: _TYPE_BODY | None = None, headers: typing.Mapping[str, str] | None = None, retries: Retry | None = None, timeout: _TYPE_TIMEOUT = _DEFAULT_TIMEOUT, chunked: bool = False, response_conn: BaseHTTPConnection | None = None, preload_content: bool = True, decode_content: bool = True, enforce_content_length: bool = True, ) -> BaseHTTPResponse: """ Perform a request on a given urllib connection object taken from our pool. :param conn: a connection from one of our connection pools :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param response_conn: Set this to ``None`` if you will handle releasing the connection or set the connection to have the response release it. :param preload_content: If True, the response's body will be preloaded during construction. :param decode_content: If True, will attempt to decode the body based on the 'content-encoding' header. :param enforce_content_length: Enforce content length checking. Body returned by server must match value of Content-Length header, if present. Otherwise, raise error. """ self.num_requests += 1 timeout_obj = self._get_timeout(timeout) timeout_obj.start_connect() conn.timeout = Timeout.resolve_default_timeout(timeout_obj.connect_timeout) try: # Trigger any extra validation we need to do. try: > self._validate_conn(conn) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=52693): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:466: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:1095: in _validate_conn conn.connect() __class__ = conn = self = /usr/lib/python3/dist-packages/urllib3/connection.py:730: in connect sock_and_verified = _ssl_wrap_socket_and_match_hostname( is_time_off = False probe_http2_host = '127.0.0.1' probe_http2_port = 52693 self = server_hostname = '127.0.0.1' server_hostname_rm_dot = '127.0.0.1' sock = target_supports_http2 = False tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/connection.py:909: in _ssl_wrap_socket_and_match_hostname ssl_sock = ssl_wrap_socket( assert_fingerprint = None assert_hostname = None ca_cert_data = None ca_cert_dir = None ca_certs = '/tmp/tmpcqpzo97_.pem' cert_file = '/tmp/tmpkn11sfyl.pem' cert_reqs = 'CERT_REQUIRED' context = default_ssl_context = True key_file = None key_password = None normalized = '127.0.0.1' server_hostname = '127.0.0.1' sock = ssl_context = None ssl_maximum_version = None ssl_minimum_version = None ssl_version = None tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/util/ssl_.py:469: in ssl_wrap_socket ssl_sock = _ssl_wrap_socket_impl(sock, context, tls_in_tls, server_hostname) ca_cert_data = None ca_cert_dir = None ca_certs = '/tmp/tmpcqpzo97_.pem' cert_reqs = None certfile = '/tmp/tmpkn11sfyl.pem' ciphers = None context = key_password = None keyfile = None server_hostname = '127.0.0.1' sock = ssl_context = ssl_version = None tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/util/ssl_.py:513: in _ssl_wrap_socket_impl return ssl_context.wrap_socket(sock, server_hostname=server_hostname) server_hostname = '127.0.0.1' sock = ssl_context = tls_in_tls = False /usr/lib/python3.13/ssl.py:455: in wrap_socket return self.sslsocket_class._create( do_handshake_on_connect = True self = server_hostname = '127.0.0.1' server_side = False session = None sock = suppress_ragged_eofs = True /usr/lib/python3.13/ssl.py:1076: in _create self.do_handshake() __class__ = cls = connected = True context = do_handshake_on_connect = True kwargs = {'family': , 'fileno': 17, 'proto': 6, 'type': } self = server_hostname = '127.0.0.1' server_side = False session = None sock = sock_timeout = 0.1 suppress_ragged_eofs = True timeout = 0.1 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , block = False @_sslcopydoc def do_handshake(self, block=False): self._check_connected() timeout = self.gettimeout() try: if timeout == 0.0 and block: self.settimeout(None) > self._sslobj.do_handshake() E TimeoutError: _ssl.c:1001: The handshake operation timed out block = False self = timeout = 0.1 /usr/lib/python3.13/ssl.py:1372: TimeoutError The above exception was the direct cause of the following exception: self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmpcqpzo97_.pem', cert = '/tmp/tmpkn11sfyl.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: > resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) cert = '/tmp/tmpkn11sfyl.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmpcqpzo97_.pem' /usr/lib/python3/dist-packages/requests/adapters.py:667: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:843: in urlopen retries = retries.increment( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=52693): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/util/retry.py:474: in increment raise reraise(type(error), error, _stacktrace) _pool = _stacktrace = cause = 'unknown' connect = None error = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=52693): Read timed out. (read timeout=0.1)") method = 'GET' other = None read = False redirect = None redirect_location = None response = None self = Retry(total=0, connect=None, read=False, redirect=None, status=None) status = None status_count = None total = -1 url = '/' /usr/lib/python3/dist-packages/urllib3/util/util.py:39: in reraise raise value tb = None tp = value = None /usr/lib/python3/dist-packages/urllib3/connectionpool.py:789: in urlopen response = self._make_request( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=52693): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:490: in _make_request raise new_e body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=52693): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:468: in _make_request self._raise_timeout(err=e, url=url, timeout_value=conn.timeout) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=52693): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = err = TimeoutError('_ssl.c:1001: The handshake operation timed out'), url = '/' timeout_value = 0.1 def _raise_timeout( self, err: BaseSSLError | OSError | SocketTimeout, url: str, timeout_value: _TYPE_TIMEOUT | None, ) -> None: """Is the error actually a timeout? Will raise a ReadTimeout or pass""" if isinstance(err, SocketTimeout): > raise ReadTimeoutError( self, url, f"Read timed out. (read timeout={timeout_value})" ) from err E urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='127.0.0.1', port=52693): Read timed out. (read timeout=0.1) err = TimeoutError('_ssl.c:1001: The handshake operation timed out') self = timeout_value = 0.1 url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:369: ReadTimeoutError During handling of the above exception, another exception occurred: http_request_timeout = 0.1 mocker = tls_http_server = functools.partial(, request=>) adapter_type = 'pyopenssl', ca = tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmpxxp1yxb4.pem' tls_certificate_private_key_pem_path = '/tmp/tmp64dtwuqc.pem' tls_ca_certificate_pem_path = '/tmp/tmpcqpzo97_.pem', is_trusted_cert = True tls_client_identity = '*.localhost', tls_verify_mode = @pytest.mark.parametrize( # noqa: C901 # FIXME 'adapter_type', ( 'builtin', 'pyopenssl', ), ) @pytest.mark.parametrize( ('is_trusted_cert', 'tls_client_identity'), ( (True, 'localhost'), (True, '127.0.0.1'), (True, '*.localhost'), (True, 'not_localhost'), (False, 'localhost'), ), ) @pytest.mark.parametrize( 'tls_verify_mode', ( ssl.CERT_NONE, # server shouldn't validate client cert ssl.CERT_OPTIONAL, # same as CERT_REQUIRED in client mode, don't use ssl.CERT_REQUIRED, # server should validate if client cert CA is OK ), ) @pytest.mark.xfail( IS_PYPY and IS_CI, reason='Fails under PyPy in CI for unknown reason', strict=False, ) def test_tls_client_auth( # noqa: C901, WPS213 # FIXME # FIXME: remove twisted logic, separate tests http_request_timeout, mocker, tls_http_server, adapter_type, ca, tls_certificate, tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, tls_ca_certificate_pem_path, is_trusted_cert, tls_client_identity, tls_verify_mode, ): """Verify that client TLS certificate auth works correctly.""" test_cert_rejection = ( tls_verify_mode != ssl.CERT_NONE and not is_trusted_cert ) interface, _host, port = _get_conn_data(ANY_INTERFACE_IPV4) client_cert_root_ca = ca if is_trusted_cert else trustme.CA() with mocker.mock_module.patch( 'idna.core.ulabel', return_value=ntob(tls_client_identity), ): client_cert = client_cert_root_ca.issue_cert( ntou(tls_client_identity), ) del client_cert_root_ca with client_cert.private_key_and_cert_chain_pem.tempfile() as cl_pem: tls_adapter_cls = get_ssl_adapter_class(name=adapter_type) tls_adapter = tls_adapter_cls( tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, ) if adapter_type == 'pyopenssl': tls_adapter.context = tls_adapter.get_context() tls_adapter.context.set_verify( _stdlib_to_openssl_verify[tls_verify_mode], lambda conn, cert, errno, depth, preverify_ok: preverify_ok, ) else: tls_adapter.context.verify_mode = tls_verify_mode ca.configure_trust(tls_adapter.context) tls_certificate.configure_cert(tls_adapter.context) tlshttpserver = tls_http_server((interface, port), tls_adapter) interface, _host, port = _get_conn_data(tlshttpserver.bind_addr) make_https_request = functools.partial( requests.get, 'https://{host!s}:{port!s}/'.format(host=interface, port=port), # Don't wait for the first byte forever: timeout=http_request_timeout, # Server TLS certificate verification: verify=tls_ca_certificate_pem_path, # Client TLS certificate verification: cert=cl_pem, ) if not test_cert_rejection: > resp = make_https_request() _host = '127.0.0.1' adapter_type = 'pyopenssl' ca = cl_pem = '/tmp/tmpkn11sfyl.pem' client_cert = http_request_timeout = 0.1 interface = '127.0.0.1' is_trusted_cert = True make_https_request = functools.partial(, 'https://127.0.0.1:52693/', timeout=0.1, verify='/tmp/tmpcqpzo97_.pem', cert='/tmp/tmpkn11sfyl.pem') mocker = port = 52693 test_cert_rejection = False tls_adapter = tls_adapter_cls = tls_ca_certificate_pem_path = '/tmp/tmpcqpzo97_.pem' tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmpxxp1yxb4.pem' tls_certificate_private_key_pem_path = '/tmp/tmp64dtwuqc.pem' tls_client_identity = '*.localhost' tls_http_server = functools.partial(, request=>) tls_verify_mode = tlshttpserver = cheroot/test/test_ssl.py:328: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/requests/api.py:73: in get return request("get", url, params=params, **kwargs) kwargs = {'cert': '/tmp/tmpkn11sfyl.pem', 'timeout': 0.1, 'verify': '/tmp/tmpcqpzo97_.pem'} params = None url = 'https://127.0.0.1:52693/' /usr/lib/python3/dist-packages/requests/api.py:59: in request return session.request(method=method, url=url, **kwargs) kwargs = {'cert': '/tmp/tmpkn11sfyl.pem', 'params': None, 'timeout': 0.1, 'verify': '/tmp/tmpcqpzo97_.pem'} method = 'get' session = url = 'https://127.0.0.1:52693/' /usr/lib/python3/dist-packages/requests/sessions.py:589: in request resp = self.send(prep, **send_kwargs) allow_redirects = True auth = None cert = '/tmp/tmpkn11sfyl.pem' cookies = None data = None files = None headers = None hooks = None json = None method = 'get' params = None prep = proxies = {'no': 'localhost'} req = self = send_kwargs = {'allow_redirects': True, 'cert': '/tmp/tmpkn11sfyl.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, ...} settings = {'cert': '/tmp/tmpkn11sfyl.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'verify': '/tmp/tmpcqpzo97_.pem'} stream = None timeout = 0.1 url = 'https://127.0.0.1:52693/' verify = '/tmp/tmpcqpzo97_.pem' /usr/lib/python3/dist-packages/requests/sessions.py:703: in send r = adapter.send(request, **kwargs) adapter = allow_redirects = True hooks = {'response': []} kwargs = {'cert': '/tmp/tmpkn11sfyl.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'timeout': 0.1, ...} request = self = start = 1733986034.6690168 stream = False _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmpcqpzo97_.pem', cert = '/tmp/tmpkn11sfyl.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) except (ProtocolError, OSError) as err: raise ConnectionError(err, request=request) except MaxRetryError as e: if isinstance(e.reason, ConnectTimeoutError): # TODO: Remove this in 3.0.0: see #2811 if not isinstance(e.reason, NewConnectionError): raise ConnectTimeout(e, request=request) if isinstance(e.reason, ResponseError): raise RetryError(e, request=request) if isinstance(e.reason, _ProxyError): raise ProxyError(e, request=request) if isinstance(e.reason, _SSLError): # This branch is for urllib3 v1.22 and later. raise SSLError(e, request=request) raise ConnectionError(e, request=request) except ClosedPoolError as e: raise ConnectionError(e, request=request) except _ProxyError as e: raise ProxyError(e) except (_SSLError, _HTTPError) as e: if isinstance(e, _SSLError): # This branch is for urllib3 versions earlier than v1.22 raise SSLError(e, request=request) elif isinstance(e, ReadTimeoutError): > raise ReadTimeout(e, request=request) E requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='127.0.0.1', port=52693): Read timed out. (read timeout=0.1) cert = '/tmp/tmpkn11sfyl.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmpcqpzo97_.pem' /usr/lib/python3/dist-packages/requests/adapters.py:713: ReadTimeout ______________ test_tls_client_auth[0-False-localhost-pyopenssl] _______________ [gw1] linux -- Python 3.13.1 /usr/bin/python3.13 self = conn = , method = 'GET' url = '/', body = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) timeout = Timeout(connect=0.1, read=0.1, total=None), chunked = False response_conn = preload_content = False, decode_content = False, enforce_content_length = True def _make_request( self, conn: BaseHTTPConnection, method: str, url: str, body: _TYPE_BODY | None = None, headers: typing.Mapping[str, str] | None = None, retries: Retry | None = None, timeout: _TYPE_TIMEOUT = _DEFAULT_TIMEOUT, chunked: bool = False, response_conn: BaseHTTPConnection | None = None, preload_content: bool = True, decode_content: bool = True, enforce_content_length: bool = True, ) -> BaseHTTPResponse: """ Perform a request on a given urllib connection object taken from our pool. :param conn: a connection from one of our connection pools :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param response_conn: Set this to ``None`` if you will handle releasing the connection or set the connection to have the response release it. :param preload_content: If True, the response's body will be preloaded during construction. :param decode_content: If True, will attempt to decode the body based on the 'content-encoding' header. :param enforce_content_length: Enforce content length checking. Body returned by server must match value of Content-Length header, if present. Otherwise, raise error. """ self.num_requests += 1 timeout_obj = self._get_timeout(timeout) timeout_obj.start_connect() conn.timeout = Timeout.resolve_default_timeout(timeout_obj.connect_timeout) try: # Trigger any extra validation we need to do. try: self._validate_conn(conn) except (SocketTimeout, BaseSSLError) as e: self._raise_timeout(err=e, url=url, timeout_value=conn.timeout) raise # _validate_conn() starts the connection to an HTTPS proxy # so we need to wrap errors with 'ProxyError' here too. except ( OSError, NewConnectionError, TimeoutError, BaseSSLError, CertificateError, SSLError, ) as e: new_e: Exception = e if isinstance(e, (BaseSSLError, CertificateError)): new_e = SSLError(e) # If the connection didn't successfully connect to it's proxy # then there if isinstance( new_e, (OSError, NewConnectionError, TimeoutError, SSLError) ) and (conn and conn.proxy and not conn.has_connected_to_proxy): new_e = _wrap_proxy_error(new_e, conn.proxy.scheme) raise new_e # conn.request() calls http.client.*.request, not the method in # urllib3.request. It also calls makefile (recv) on the socket. try: conn.request( method, url, body=body, headers=headers, chunked=chunked, preload_content=preload_content, decode_content=decode_content, enforce_content_length=enforce_content_length, ) # We are swallowing BrokenPipeError (errno.EPIPE) since the server is # legitimately able to close the connection after sending a valid response. # With this behaviour, the received response is still readable. except BrokenPipeError: pass except OSError as e: # MacOS/Linux # EPROTOTYPE and ECONNRESET are needed on macOS # https://erickt.github.io/blog/2014/11/19/adventures-in-debugging-a-potential-osx-kernel-bug/ # Condition changed later to emit ECONNRESET instead of only EPROTOTYPE. if e.errno != errno.EPROTOTYPE and e.errno != errno.ECONNRESET: raise # Reset the timeout for the recv() on the socket read_timeout = timeout_obj.read_timeout if not conn.is_closed: # In Python 3 socket.py will catch EAGAIN and return None when you # try and read into the file pointer created by http.client, which # instead raises a BadStatusLine exception. Instead of catching # the exception and assuming all BadStatusLine exceptions are read # timeouts, check for a zero timeout before making the request. if read_timeout == 0: raise ReadTimeoutError( self, url, f"Read timed out. (read timeout={read_timeout})" ) conn.timeout = read_timeout # Receive the response from the server try: > response = conn.getresponse() body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' preload_content = False read_timeout = 0.1 response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:536: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connection.py:507: in getresponse httplib_response = super().getresponse() HTTPResponse = __class__ = resp_options = _ResponseOptions(request_method='GET', request_url='/', preload_content=False, decode_content=False, enforce_content_length=True) self = /usr/lib/python3.13/http/client.py:1428: in getresponse response.begin() response = self = /usr/lib/python3.13/http/client.py:331: in begin version, status, reason = self._read_status() self = /usr/lib/python3.13/http/client.py:292: in _read_status line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1") self = /usr/lib/python3.13/socket.py:719: in readinto return self._sock.recv_into(b) b = self = /usr/lib/python3.13/ssl.py:1304: in recv_into return self.read(nbytes, buffer) __class__ = buffer = flags = 0 nbytes = 8192 self = view = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , len = 8192 buffer = def read(self, len=1024, buffer=None): """Read up to LEN bytes and return them. Return zero-length string on EOF.""" self._checkClosed() if self._sslobj is None: raise ValueError("Read on closed or unwrapped SSL socket.") try: if buffer is not None: > return self._sslobj.read(len, buffer) E TimeoutError: The read operation timed out buffer = len = 8192 self = /usr/lib/python3.13/ssl.py:1138: TimeoutError The above exception was the direct cause of the following exception: self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmplh7n1b33.pem', cert = '/tmp/tmpskdwnntg.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: > resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) cert = '/tmp/tmpskdwnntg.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmplh7n1b33.pem' /usr/lib/python3/dist-packages/requests/adapters.py:667: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:843: in urlopen retries = retries.increment( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=50775): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/util/retry.py:474: in increment raise reraise(type(error), error, _stacktrace) _pool = _stacktrace = cause = 'unknown' connect = None error = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=50775): Read timed out. (read timeout=0.1)") method = 'GET' other = None read = False redirect = None redirect_location = None response = None self = Retry(total=0, connect=None, read=False, redirect=None, status=None) status = None status_count = None total = -1 url = '/' /usr/lib/python3/dist-packages/urllib3/util/util.py:39: in reraise raise value tb = None tp = value = None /usr/lib/python3/dist-packages/urllib3/connectionpool.py:789: in urlopen response = self._make_request( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=50775): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:538: in _make_request self._raise_timeout(err=e, url=url, timeout_value=read_timeout) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' preload_content = False read_timeout = 0.1 response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = err = TimeoutError('The read operation timed out'), url = '/' timeout_value = 0.1 def _raise_timeout( self, err: BaseSSLError | OSError | SocketTimeout, url: str, timeout_value: _TYPE_TIMEOUT | None, ) -> None: """Is the error actually a timeout? Will raise a ReadTimeout or pass""" if isinstance(err, SocketTimeout): > raise ReadTimeoutError( self, url, f"Read timed out. (read timeout={timeout_value})" ) from err E urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='127.0.0.1', port=50775): Read timed out. (read timeout=0.1) err = TimeoutError('The read operation timed out') self = timeout_value = 0.1 url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:369: ReadTimeoutError During handling of the above exception, another exception occurred: http_request_timeout = 0.1 mocker = tls_http_server = functools.partial(, request=>) adapter_type = 'pyopenssl', ca = tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmp604phabm.pem' tls_certificate_private_key_pem_path = '/tmp/tmpppmk8mu1.pem' tls_ca_certificate_pem_path = '/tmp/tmplh7n1b33.pem', is_trusted_cert = False tls_client_identity = 'localhost', tls_verify_mode = @pytest.mark.parametrize( # noqa: C901 # FIXME 'adapter_type', ( 'builtin', 'pyopenssl', ), ) @pytest.mark.parametrize( ('is_trusted_cert', 'tls_client_identity'), ( (True, 'localhost'), (True, '127.0.0.1'), (True, '*.localhost'), (True, 'not_localhost'), (False, 'localhost'), ), ) @pytest.mark.parametrize( 'tls_verify_mode', ( ssl.CERT_NONE, # server shouldn't validate client cert ssl.CERT_OPTIONAL, # same as CERT_REQUIRED in client mode, don't use ssl.CERT_REQUIRED, # server should validate if client cert CA is OK ), ) @pytest.mark.xfail( IS_PYPY and IS_CI, reason='Fails under PyPy in CI for unknown reason', strict=False, ) def test_tls_client_auth( # noqa: C901, WPS213 # FIXME # FIXME: remove twisted logic, separate tests http_request_timeout, mocker, tls_http_server, adapter_type, ca, tls_certificate, tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, tls_ca_certificate_pem_path, is_trusted_cert, tls_client_identity, tls_verify_mode, ): """Verify that client TLS certificate auth works correctly.""" test_cert_rejection = ( tls_verify_mode != ssl.CERT_NONE and not is_trusted_cert ) interface, _host, port = _get_conn_data(ANY_INTERFACE_IPV4) client_cert_root_ca = ca if is_trusted_cert else trustme.CA() with mocker.mock_module.patch( 'idna.core.ulabel', return_value=ntob(tls_client_identity), ): client_cert = client_cert_root_ca.issue_cert( ntou(tls_client_identity), ) del client_cert_root_ca with client_cert.private_key_and_cert_chain_pem.tempfile() as cl_pem: tls_adapter_cls = get_ssl_adapter_class(name=adapter_type) tls_adapter = tls_adapter_cls( tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, ) if adapter_type == 'pyopenssl': tls_adapter.context = tls_adapter.get_context() tls_adapter.context.set_verify( _stdlib_to_openssl_verify[tls_verify_mode], lambda conn, cert, errno, depth, preverify_ok: preverify_ok, ) else: tls_adapter.context.verify_mode = tls_verify_mode ca.configure_trust(tls_adapter.context) tls_certificate.configure_cert(tls_adapter.context) tlshttpserver = tls_http_server((interface, port), tls_adapter) interface, _host, port = _get_conn_data(tlshttpserver.bind_addr) make_https_request = functools.partial( requests.get, 'https://{host!s}:{port!s}/'.format(host=interface, port=port), # Don't wait for the first byte forever: timeout=http_request_timeout, # Server TLS certificate verification: verify=tls_ca_certificate_pem_path, # Client TLS certificate verification: cert=cl_pem, ) if not test_cert_rejection: > resp = make_https_request() _host = '127.0.0.1' adapter_type = 'pyopenssl' ca = cl_pem = '/tmp/tmpskdwnntg.pem' client_cert = http_request_timeout = 0.1 interface = '127.0.0.1' is_trusted_cert = False make_https_request = functools.partial(, 'https://127.0.0.1:50775/', timeout=0.1, verify='/tmp/tmplh7n1b33.pem', cert='/tmp/tmpskdwnntg.pem') mocker = port = 50775 test_cert_rejection = False tls_adapter = tls_adapter_cls = tls_ca_certificate_pem_path = '/tmp/tmplh7n1b33.pem' tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmp604phabm.pem' tls_certificate_private_key_pem_path = '/tmp/tmpppmk8mu1.pem' tls_client_identity = 'localhost' tls_http_server = functools.partial(, request=>) tls_verify_mode = tlshttpserver = cheroot/test/test_ssl.py:328: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/requests/api.py:73: in get return request("get", url, params=params, **kwargs) kwargs = {'cert': '/tmp/tmpskdwnntg.pem', 'timeout': 0.1, 'verify': '/tmp/tmplh7n1b33.pem'} params = None url = 'https://127.0.0.1:50775/' /usr/lib/python3/dist-packages/requests/api.py:59: in request return session.request(method=method, url=url, **kwargs) kwargs = {'cert': '/tmp/tmpskdwnntg.pem', 'params': None, 'timeout': 0.1, 'verify': '/tmp/tmplh7n1b33.pem'} method = 'get' session = url = 'https://127.0.0.1:50775/' /usr/lib/python3/dist-packages/requests/sessions.py:589: in request resp = self.send(prep, **send_kwargs) allow_redirects = True auth = None cert = '/tmp/tmpskdwnntg.pem' cookies = None data = None files = None headers = None hooks = None json = None method = 'get' params = None prep = proxies = {'no': 'localhost'} req = self = send_kwargs = {'allow_redirects': True, 'cert': '/tmp/tmpskdwnntg.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, ...} settings = {'cert': '/tmp/tmpskdwnntg.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'verify': '/tmp/tmplh7n1b33.pem'} stream = None timeout = 0.1 url = 'https://127.0.0.1:50775/' verify = '/tmp/tmplh7n1b33.pem' /usr/lib/python3/dist-packages/requests/sessions.py:703: in send r = adapter.send(request, **kwargs) adapter = allow_redirects = True hooks = {'response': []} kwargs = {'cert': '/tmp/tmpskdwnntg.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'timeout': 0.1, ...} request = self = start = 1733986034.6093793 stream = False _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmplh7n1b33.pem', cert = '/tmp/tmpskdwnntg.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) except (ProtocolError, OSError) as err: raise ConnectionError(err, request=request) except MaxRetryError as e: if isinstance(e.reason, ConnectTimeoutError): # TODO: Remove this in 3.0.0: see #2811 if not isinstance(e.reason, NewConnectionError): raise ConnectTimeout(e, request=request) if isinstance(e.reason, ResponseError): raise RetryError(e, request=request) if isinstance(e.reason, _ProxyError): raise ProxyError(e, request=request) if isinstance(e.reason, _SSLError): # This branch is for urllib3 v1.22 and later. raise SSLError(e, request=request) raise ConnectionError(e, request=request) except ClosedPoolError as e: raise ConnectionError(e, request=request) except _ProxyError as e: raise ProxyError(e) except (_SSLError, _HTTPError) as e: if isinstance(e, _SSLError): # This branch is for urllib3 versions earlier than v1.22 raise SSLError(e, request=request) elif isinstance(e, ReadTimeoutError): > raise ReadTimeout(e, request=request) E requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='127.0.0.1', port=50775): Read timed out. (read timeout=0.1) cert = '/tmp/tmpskdwnntg.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmplh7n1b33.pem' /usr/lib/python3/dist-packages/requests/adapters.py:713: ReadTimeout ______________ test_tls_client_auth[0-True-not_localhost-builtin] ______________ [gw11] linux -- Python 3.13.1 /usr/bin/python3.13 self = conn = , method = 'GET' url = '/', body = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) timeout = Timeout(connect=0.1, read=0.1, total=None), chunked = False response_conn = preload_content = False, decode_content = False, enforce_content_length = True def _make_request( self, conn: BaseHTTPConnection, method: str, url: str, body: _TYPE_BODY | None = None, headers: typing.Mapping[str, str] | None = None, retries: Retry | None = None, timeout: _TYPE_TIMEOUT = _DEFAULT_TIMEOUT, chunked: bool = False, response_conn: BaseHTTPConnection | None = None, preload_content: bool = True, decode_content: bool = True, enforce_content_length: bool = True, ) -> BaseHTTPResponse: """ Perform a request on a given urllib connection object taken from our pool. :param conn: a connection from one of our connection pools :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param response_conn: Set this to ``None`` if you will handle releasing the connection or set the connection to have the response release it. :param preload_content: If True, the response's body will be preloaded during construction. :param decode_content: If True, will attempt to decode the body based on the 'content-encoding' header. :param enforce_content_length: Enforce content length checking. Body returned by server must match value of Content-Length header, if present. Otherwise, raise error. """ self.num_requests += 1 timeout_obj = self._get_timeout(timeout) timeout_obj.start_connect() conn.timeout = Timeout.resolve_default_timeout(timeout_obj.connect_timeout) try: # Trigger any extra validation we need to do. try: self._validate_conn(conn) except (SocketTimeout, BaseSSLError) as e: self._raise_timeout(err=e, url=url, timeout_value=conn.timeout) raise # _validate_conn() starts the connection to an HTTPS proxy # so we need to wrap errors with 'ProxyError' here too. except ( OSError, NewConnectionError, TimeoutError, BaseSSLError, CertificateError, SSLError, ) as e: new_e: Exception = e if isinstance(e, (BaseSSLError, CertificateError)): new_e = SSLError(e) # If the connection didn't successfully connect to it's proxy # then there if isinstance( new_e, (OSError, NewConnectionError, TimeoutError, SSLError) ) and (conn and conn.proxy and not conn.has_connected_to_proxy): new_e = _wrap_proxy_error(new_e, conn.proxy.scheme) raise new_e # conn.request() calls http.client.*.request, not the method in # urllib3.request. It also calls makefile (recv) on the socket. try: conn.request( method, url, body=body, headers=headers, chunked=chunked, preload_content=preload_content, decode_content=decode_content, enforce_content_length=enforce_content_length, ) # We are swallowing BrokenPipeError (errno.EPIPE) since the server is # legitimately able to close the connection after sending a valid response. # With this behaviour, the received response is still readable. except BrokenPipeError: pass except OSError as e: # MacOS/Linux # EPROTOTYPE and ECONNRESET are needed on macOS # https://erickt.github.io/blog/2014/11/19/adventures-in-debugging-a-potential-osx-kernel-bug/ # Condition changed later to emit ECONNRESET instead of only EPROTOTYPE. if e.errno != errno.EPROTOTYPE and e.errno != errno.ECONNRESET: raise # Reset the timeout for the recv() on the socket read_timeout = timeout_obj.read_timeout if not conn.is_closed: # In Python 3 socket.py will catch EAGAIN and return None when you # try and read into the file pointer created by http.client, which # instead raises a BadStatusLine exception. Instead of catching # the exception and assuming all BadStatusLine exceptions are read # timeouts, check for a zero timeout before making the request. if read_timeout == 0: raise ReadTimeoutError( self, url, f"Read timed out. (read timeout={read_timeout})" ) conn.timeout = read_timeout # Receive the response from the server try: > response = conn.getresponse() body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' preload_content = False read_timeout = 0.1 response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:536: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connection.py:507: in getresponse httplib_response = super().getresponse() HTTPResponse = __class__ = resp_options = _ResponseOptions(request_method='GET', request_url='/', preload_content=False, decode_content=False, enforce_content_length=True) self = /usr/lib/python3.13/http/client.py:1428: in getresponse response.begin() response = self = /usr/lib/python3.13/http/client.py:331: in begin version, status, reason = self._read_status() self = /usr/lib/python3.13/http/client.py:292: in _read_status line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1") self = /usr/lib/python3.13/socket.py:719: in readinto return self._sock.recv_into(b) b = self = /usr/lib/python3.13/ssl.py:1304: in recv_into return self.read(nbytes, buffer) __class__ = buffer = flags = 0 nbytes = 8192 self = view = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , len = 8192 buffer = def read(self, len=1024, buffer=None): """Read up to LEN bytes and return them. Return zero-length string on EOF.""" self._checkClosed() if self._sslobj is None: raise ValueError("Read on closed or unwrapped SSL socket.") try: if buffer is not None: > return self._sslobj.read(len, buffer) E TimeoutError: The read operation timed out buffer = len = 8192 self = /usr/lib/python3.13/ssl.py:1138: TimeoutError The above exception was the direct cause of the following exception: self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmpzmd7ydyg.pem', cert = '/tmp/tmp9wdrkeko.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: > resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) cert = '/tmp/tmp9wdrkeko.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmpzmd7ydyg.pem' /usr/lib/python3/dist-packages/requests/adapters.py:667: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:843: in urlopen retries = retries.increment( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=36229): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/util/retry.py:474: in increment raise reraise(type(error), error, _stacktrace) _pool = _stacktrace = cause = 'unknown' connect = None error = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=36229): Read timed out. (read timeout=0.1)") method = 'GET' other = None read = False redirect = None redirect_location = None response = None self = Retry(total=0, connect=None, read=False, redirect=None, status=None) status = None status_count = None total = -1 url = '/' /usr/lib/python3/dist-packages/urllib3/util/util.py:39: in reraise raise value tb = None tp = value = None /usr/lib/python3/dist-packages/urllib3/connectionpool.py:789: in urlopen response = self._make_request( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=36229): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:538: in _make_request self._raise_timeout(err=e, url=url, timeout_value=read_timeout) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' preload_content = False read_timeout = 0.1 response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = err = TimeoutError('The read operation timed out'), url = '/' timeout_value = 0.1 def _raise_timeout( self, err: BaseSSLError | OSError | SocketTimeout, url: str, timeout_value: _TYPE_TIMEOUT | None, ) -> None: """Is the error actually a timeout? Will raise a ReadTimeout or pass""" if isinstance(err, SocketTimeout): > raise ReadTimeoutError( self, url, f"Read timed out. (read timeout={timeout_value})" ) from err E urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='127.0.0.1', port=36229): Read timed out. (read timeout=0.1) err = TimeoutError('The read operation timed out') self = timeout_value = 0.1 url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:369: ReadTimeoutError During handling of the above exception, another exception occurred: http_request_timeout = 0.1 mocker = tls_http_server = functools.partial(, request=>) adapter_type = 'builtin', ca = tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmpresg642i.pem' tls_certificate_private_key_pem_path = '/tmp/tmp13o4n5z9.pem' tls_ca_certificate_pem_path = '/tmp/tmpzmd7ydyg.pem', is_trusted_cert = True tls_client_identity = 'not_localhost' tls_verify_mode = @pytest.mark.parametrize( # noqa: C901 # FIXME 'adapter_type', ( 'builtin', 'pyopenssl', ), ) @pytest.mark.parametrize( ('is_trusted_cert', 'tls_client_identity'), ( (True, 'localhost'), (True, '127.0.0.1'), (True, '*.localhost'), (True, 'not_localhost'), (False, 'localhost'), ), ) @pytest.mark.parametrize( 'tls_verify_mode', ( ssl.CERT_NONE, # server shouldn't validate client cert ssl.CERT_OPTIONAL, # same as CERT_REQUIRED in client mode, don't use ssl.CERT_REQUIRED, # server should validate if client cert CA is OK ), ) @pytest.mark.xfail( IS_PYPY and IS_CI, reason='Fails under PyPy in CI for unknown reason', strict=False, ) def test_tls_client_auth( # noqa: C901, WPS213 # FIXME # FIXME: remove twisted logic, separate tests http_request_timeout, mocker, tls_http_server, adapter_type, ca, tls_certificate, tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, tls_ca_certificate_pem_path, is_trusted_cert, tls_client_identity, tls_verify_mode, ): """Verify that client TLS certificate auth works correctly.""" test_cert_rejection = ( tls_verify_mode != ssl.CERT_NONE and not is_trusted_cert ) interface, _host, port = _get_conn_data(ANY_INTERFACE_IPV4) client_cert_root_ca = ca if is_trusted_cert else trustme.CA() with mocker.mock_module.patch( 'idna.core.ulabel', return_value=ntob(tls_client_identity), ): client_cert = client_cert_root_ca.issue_cert( ntou(tls_client_identity), ) del client_cert_root_ca with client_cert.private_key_and_cert_chain_pem.tempfile() as cl_pem: tls_adapter_cls = get_ssl_adapter_class(name=adapter_type) tls_adapter = tls_adapter_cls( tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, ) if adapter_type == 'pyopenssl': tls_adapter.context = tls_adapter.get_context() tls_adapter.context.set_verify( _stdlib_to_openssl_verify[tls_verify_mode], lambda conn, cert, errno, depth, preverify_ok: preverify_ok, ) else: tls_adapter.context.verify_mode = tls_verify_mode ca.configure_trust(tls_adapter.context) tls_certificate.configure_cert(tls_adapter.context) tlshttpserver = tls_http_server((interface, port), tls_adapter) interface, _host, port = _get_conn_data(tlshttpserver.bind_addr) make_https_request = functools.partial( requests.get, 'https://{host!s}:{port!s}/'.format(host=interface, port=port), # Don't wait for the first byte forever: timeout=http_request_timeout, # Server TLS certificate verification: verify=tls_ca_certificate_pem_path, # Client TLS certificate verification: cert=cl_pem, ) if not test_cert_rejection: > resp = make_https_request() _host = '127.0.0.1' adapter_type = 'builtin' ca = cl_pem = '/tmp/tmp9wdrkeko.pem' client_cert = http_request_timeout = 0.1 interface = '127.0.0.1' is_trusted_cert = True make_https_request = functools.partial(, 'https://127.0.0.1:36229/', timeout=0.1, verify='/tmp/tmpzmd7ydyg.pem', cert='/tmp/tmp9wdrkeko.pem') mocker = port = 36229 test_cert_rejection = False tls_adapter = tls_adapter_cls = tls_ca_certificate_pem_path = '/tmp/tmpzmd7ydyg.pem' tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmpresg642i.pem' tls_certificate_private_key_pem_path = '/tmp/tmp13o4n5z9.pem' tls_client_identity = 'not_localhost' tls_http_server = functools.partial(, request=>) tls_verify_mode = tlshttpserver = cheroot/test/test_ssl.py:328: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/requests/api.py:73: in get return request("get", url, params=params, **kwargs) kwargs = {'cert': '/tmp/tmp9wdrkeko.pem', 'timeout': 0.1, 'verify': '/tmp/tmpzmd7ydyg.pem'} params = None url = 'https://127.0.0.1:36229/' /usr/lib/python3/dist-packages/requests/api.py:59: in request return session.request(method=method, url=url, **kwargs) kwargs = {'cert': '/tmp/tmp9wdrkeko.pem', 'params': None, 'timeout': 0.1, 'verify': '/tmp/tmpzmd7ydyg.pem'} method = 'get' session = url = 'https://127.0.0.1:36229/' /usr/lib/python3/dist-packages/requests/sessions.py:589: in request resp = self.send(prep, **send_kwargs) allow_redirects = True auth = None cert = '/tmp/tmp9wdrkeko.pem' cookies = None data = None files = None headers = None hooks = None json = None method = 'get' params = None prep = proxies = {'no': 'localhost'} req = self = send_kwargs = {'allow_redirects': True, 'cert': '/tmp/tmp9wdrkeko.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, ...} settings = {'cert': '/tmp/tmp9wdrkeko.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'verify': '/tmp/tmpzmd7ydyg.pem'} stream = None timeout = 0.1 url = 'https://127.0.0.1:36229/' verify = '/tmp/tmpzmd7ydyg.pem' /usr/lib/python3/dist-packages/requests/sessions.py:703: in send r = adapter.send(request, **kwargs) adapter = allow_redirects = True hooks = {'response': []} kwargs = {'cert': '/tmp/tmp9wdrkeko.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'timeout': 0.1, ...} request = self = start = 1733986037.1244302 stream = False _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmpzmd7ydyg.pem', cert = '/tmp/tmp9wdrkeko.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) except (ProtocolError, OSError) as err: raise ConnectionError(err, request=request) except MaxRetryError as e: if isinstance(e.reason, ConnectTimeoutError): # TODO: Remove this in 3.0.0: see #2811 if not isinstance(e.reason, NewConnectionError): raise ConnectTimeout(e, request=request) if isinstance(e.reason, ResponseError): raise RetryError(e, request=request) if isinstance(e.reason, _ProxyError): raise ProxyError(e, request=request) if isinstance(e.reason, _SSLError): # This branch is for urllib3 v1.22 and later. raise SSLError(e, request=request) raise ConnectionError(e, request=request) except ClosedPoolError as e: raise ConnectionError(e, request=request) except _ProxyError as e: raise ProxyError(e) except (_SSLError, _HTTPError) as e: if isinstance(e, _SSLError): # This branch is for urllib3 versions earlier than v1.22 raise SSLError(e, request=request) elif isinstance(e, ReadTimeoutError): > raise ReadTimeout(e, request=request) E requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='127.0.0.1', port=36229): Read timed out. (read timeout=0.1) cert = '/tmp/tmp9wdrkeko.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmpzmd7ydyg.pem' /usr/lib/python3/dist-packages/requests/adapters.py:713: ReadTimeout _____________ test_tls_client_auth[1-True-not_localhost-pyopenssl] _____________ [gw12] linux -- Python 3.13.1 /usr/bin/python3.13 self = conn = , method = 'GET' url = '/', body = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) timeout = Timeout(connect=0.1, read=0.1, total=None), chunked = False response_conn = preload_content = False, decode_content = False, enforce_content_length = True def _make_request( self, conn: BaseHTTPConnection, method: str, url: str, body: _TYPE_BODY | None = None, headers: typing.Mapping[str, str] | None = None, retries: Retry | None = None, timeout: _TYPE_TIMEOUT = _DEFAULT_TIMEOUT, chunked: bool = False, response_conn: BaseHTTPConnection | None = None, preload_content: bool = True, decode_content: bool = True, enforce_content_length: bool = True, ) -> BaseHTTPResponse: """ Perform a request on a given urllib connection object taken from our pool. :param conn: a connection from one of our connection pools :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param response_conn: Set this to ``None`` if you will handle releasing the connection or set the connection to have the response release it. :param preload_content: If True, the response's body will be preloaded during construction. :param decode_content: If True, will attempt to decode the body based on the 'content-encoding' header. :param enforce_content_length: Enforce content length checking. Body returned by server must match value of Content-Length header, if present. Otherwise, raise error. """ self.num_requests += 1 timeout_obj = self._get_timeout(timeout) timeout_obj.start_connect() conn.timeout = Timeout.resolve_default_timeout(timeout_obj.connect_timeout) try: # Trigger any extra validation we need to do. try: > self._validate_conn(conn) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=60481): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:466: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:1095: in _validate_conn conn.connect() __class__ = conn = self = /usr/lib/python3/dist-packages/urllib3/connection.py:730: in connect sock_and_verified = _ssl_wrap_socket_and_match_hostname( is_time_off = False probe_http2_host = '127.0.0.1' probe_http2_port = 60481 self = server_hostname = '127.0.0.1' server_hostname_rm_dot = '127.0.0.1' sock = target_supports_http2 = False tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/connection.py:909: in _ssl_wrap_socket_and_match_hostname ssl_sock = ssl_wrap_socket( assert_fingerprint = None assert_hostname = None ca_cert_data = None ca_cert_dir = None ca_certs = '/tmp/tmphqucff6c.pem' cert_file = '/tmp/tmpsdmfrp17.pem' cert_reqs = 'CERT_REQUIRED' context = default_ssl_context = True key_file = None key_password = None normalized = '127.0.0.1' server_hostname = '127.0.0.1' sock = ssl_context = None ssl_maximum_version = None ssl_minimum_version = None ssl_version = None tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/util/ssl_.py:469: in ssl_wrap_socket ssl_sock = _ssl_wrap_socket_impl(sock, context, tls_in_tls, server_hostname) ca_cert_data = None ca_cert_dir = None ca_certs = '/tmp/tmphqucff6c.pem' cert_reqs = None certfile = '/tmp/tmpsdmfrp17.pem' ciphers = None context = key_password = None keyfile = None server_hostname = '127.0.0.1' sock = ssl_context = ssl_version = None tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/util/ssl_.py:513: in _ssl_wrap_socket_impl return ssl_context.wrap_socket(sock, server_hostname=server_hostname) server_hostname = '127.0.0.1' sock = ssl_context = tls_in_tls = False /usr/lib/python3.13/ssl.py:455: in wrap_socket return self.sslsocket_class._create( do_handshake_on_connect = True self = server_hostname = '127.0.0.1' server_side = False session = None sock = suppress_ragged_eofs = True /usr/lib/python3.13/ssl.py:1076: in _create self.do_handshake() __class__ = cls = connected = True context = do_handshake_on_connect = True kwargs = {'family': , 'fileno': 16, 'proto': 6, 'type': } self = server_hostname = '127.0.0.1' server_side = False session = None sock = sock_timeout = 0.1 suppress_ragged_eofs = True timeout = 0.1 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , block = False @_sslcopydoc def do_handshake(self, block=False): self._check_connected() timeout = self.gettimeout() try: if timeout == 0.0 and block: self.settimeout(None) > self._sslobj.do_handshake() E TimeoutError: _ssl.c:1001: The handshake operation timed out block = False self = timeout = 0.1 /usr/lib/python3.13/ssl.py:1372: TimeoutError The above exception was the direct cause of the following exception: self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmphqucff6c.pem', cert = '/tmp/tmpsdmfrp17.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: > resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) cert = '/tmp/tmpsdmfrp17.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmphqucff6c.pem' /usr/lib/python3/dist-packages/requests/adapters.py:667: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:843: in urlopen retries = retries.increment( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=60481): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/util/retry.py:474: in increment raise reraise(type(error), error, _stacktrace) _pool = _stacktrace = cause = 'unknown' connect = None error = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=60481): Read timed out. (read timeout=0.1)") method = 'GET' other = None read = False redirect = None redirect_location = None response = None self = Retry(total=0, connect=None, read=False, redirect=None, status=None) status = None status_count = None total = -1 url = '/' /usr/lib/python3/dist-packages/urllib3/util/util.py:39: in reraise raise value tb = None tp = value = None /usr/lib/python3/dist-packages/urllib3/connectionpool.py:789: in urlopen response = self._make_request( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=60481): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:490: in _make_request raise new_e body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=60481): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:468: in _make_request self._raise_timeout(err=e, url=url, timeout_value=conn.timeout) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=60481): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = err = TimeoutError('_ssl.c:1001: The handshake operation timed out'), url = '/' timeout_value = 0.1 def _raise_timeout( self, err: BaseSSLError | OSError | SocketTimeout, url: str, timeout_value: _TYPE_TIMEOUT | None, ) -> None: """Is the error actually a timeout? Will raise a ReadTimeout or pass""" if isinstance(err, SocketTimeout): > raise ReadTimeoutError( self, url, f"Read timed out. (read timeout={timeout_value})" ) from err E urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='127.0.0.1', port=60481): Read timed out. (read timeout=0.1) err = TimeoutError('_ssl.c:1001: The handshake operation timed out') self = timeout_value = 0.1 url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:369: ReadTimeoutError During handling of the above exception, another exception occurred: http_request_timeout = 0.1 mocker = tls_http_server = functools.partial(, request=>) adapter_type = 'pyopenssl', ca = tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmpzkt2l90o.pem' tls_certificate_private_key_pem_path = '/tmp/tmpfg0_94zo.pem' tls_ca_certificate_pem_path = '/tmp/tmphqucff6c.pem', is_trusted_cert = True tls_client_identity = 'not_localhost' tls_verify_mode = @pytest.mark.parametrize( # noqa: C901 # FIXME 'adapter_type', ( 'builtin', 'pyopenssl', ), ) @pytest.mark.parametrize( ('is_trusted_cert', 'tls_client_identity'), ( (True, 'localhost'), (True, '127.0.0.1'), (True, '*.localhost'), (True, 'not_localhost'), (False, 'localhost'), ), ) @pytest.mark.parametrize( 'tls_verify_mode', ( ssl.CERT_NONE, # server shouldn't validate client cert ssl.CERT_OPTIONAL, # same as CERT_REQUIRED in client mode, don't use ssl.CERT_REQUIRED, # server should validate if client cert CA is OK ), ) @pytest.mark.xfail( IS_PYPY and IS_CI, reason='Fails under PyPy in CI for unknown reason', strict=False, ) def test_tls_client_auth( # noqa: C901, WPS213 # FIXME # FIXME: remove twisted logic, separate tests http_request_timeout, mocker, tls_http_server, adapter_type, ca, tls_certificate, tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, tls_ca_certificate_pem_path, is_trusted_cert, tls_client_identity, tls_verify_mode, ): """Verify that client TLS certificate auth works correctly.""" test_cert_rejection = ( tls_verify_mode != ssl.CERT_NONE and not is_trusted_cert ) interface, _host, port = _get_conn_data(ANY_INTERFACE_IPV4) client_cert_root_ca = ca if is_trusted_cert else trustme.CA() with mocker.mock_module.patch( 'idna.core.ulabel', return_value=ntob(tls_client_identity), ): client_cert = client_cert_root_ca.issue_cert( ntou(tls_client_identity), ) del client_cert_root_ca with client_cert.private_key_and_cert_chain_pem.tempfile() as cl_pem: tls_adapter_cls = get_ssl_adapter_class(name=adapter_type) tls_adapter = tls_adapter_cls( tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, ) if adapter_type == 'pyopenssl': tls_adapter.context = tls_adapter.get_context() tls_adapter.context.set_verify( _stdlib_to_openssl_verify[tls_verify_mode], lambda conn, cert, errno, depth, preverify_ok: preverify_ok, ) else: tls_adapter.context.verify_mode = tls_verify_mode ca.configure_trust(tls_adapter.context) tls_certificate.configure_cert(tls_adapter.context) tlshttpserver = tls_http_server((interface, port), tls_adapter) interface, _host, port = _get_conn_data(tlshttpserver.bind_addr) make_https_request = functools.partial( requests.get, 'https://{host!s}:{port!s}/'.format(host=interface, port=port), # Don't wait for the first byte forever: timeout=http_request_timeout, # Server TLS certificate verification: verify=tls_ca_certificate_pem_path, # Client TLS certificate verification: cert=cl_pem, ) if not test_cert_rejection: > resp = make_https_request() _host = '127.0.0.1' adapter_type = 'pyopenssl' ca = cl_pem = '/tmp/tmpsdmfrp17.pem' client_cert = http_request_timeout = 0.1 interface = '127.0.0.1' is_trusted_cert = True make_https_request = functools.partial(, 'https://127.0.0.1:60481/', timeout=0.1, verify='/tmp/tmphqucff6c.pem', cert='/tmp/tmpsdmfrp17.pem') mocker = port = 60481 test_cert_rejection = False tls_adapter = tls_adapter_cls = tls_ca_certificate_pem_path = '/tmp/tmphqucff6c.pem' tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmpzkt2l90o.pem' tls_certificate_private_key_pem_path = '/tmp/tmpfg0_94zo.pem' tls_client_identity = 'not_localhost' tls_http_server = functools.partial(, request=>) tls_verify_mode = tlshttpserver = cheroot/test/test_ssl.py:328: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/requests/api.py:73: in get return request("get", url, params=params, **kwargs) kwargs = {'cert': '/tmp/tmpsdmfrp17.pem', 'timeout': 0.1, 'verify': '/tmp/tmphqucff6c.pem'} params = None url = 'https://127.0.0.1:60481/' /usr/lib/python3/dist-packages/requests/api.py:59: in request return session.request(method=method, url=url, **kwargs) kwargs = {'cert': '/tmp/tmpsdmfrp17.pem', 'params': None, 'timeout': 0.1, 'verify': '/tmp/tmphqucff6c.pem'} method = 'get' session = url = 'https://127.0.0.1:60481/' /usr/lib/python3/dist-packages/requests/sessions.py:589: in request resp = self.send(prep, **send_kwargs) allow_redirects = True auth = None cert = '/tmp/tmpsdmfrp17.pem' cookies = None data = None files = None headers = None hooks = None json = None method = 'get' params = None prep = proxies = {'no': 'localhost'} req = self = send_kwargs = {'allow_redirects': True, 'cert': '/tmp/tmpsdmfrp17.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, ...} settings = {'cert': '/tmp/tmpsdmfrp17.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'verify': '/tmp/tmphqucff6c.pem'} stream = None timeout = 0.1 url = 'https://127.0.0.1:60481/' verify = '/tmp/tmphqucff6c.pem' /usr/lib/python3/dist-packages/requests/sessions.py:703: in send r = adapter.send(request, **kwargs) adapter = allow_redirects = True hooks = {'response': []} kwargs = {'cert': '/tmp/tmpsdmfrp17.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'timeout': 0.1, ...} request = self = start = 1733986035.8993185 stream = False _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmphqucff6c.pem', cert = '/tmp/tmpsdmfrp17.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) except (ProtocolError, OSError) as err: raise ConnectionError(err, request=request) except MaxRetryError as e: if isinstance(e.reason, ConnectTimeoutError): # TODO: Remove this in 3.0.0: see #2811 if not isinstance(e.reason, NewConnectionError): raise ConnectTimeout(e, request=request) if isinstance(e.reason, ResponseError): raise RetryError(e, request=request) if isinstance(e.reason, _ProxyError): raise ProxyError(e, request=request) if isinstance(e.reason, _SSLError): # This branch is for urllib3 v1.22 and later. raise SSLError(e, request=request) raise ConnectionError(e, request=request) except ClosedPoolError as e: raise ConnectionError(e, request=request) except _ProxyError as e: raise ProxyError(e) except (_SSLError, _HTTPError) as e: if isinstance(e, _SSLError): # This branch is for urllib3 versions earlier than v1.22 raise SSLError(e, request=request) elif isinstance(e, ReadTimeoutError): > raise ReadTimeout(e, request=request) E requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='127.0.0.1', port=60481): Read timed out. (read timeout=0.1) cert = '/tmp/tmpsdmfrp17.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmphqucff6c.pem' /usr/lib/python3/dist-packages/requests/adapters.py:713: ReadTimeout _______________ test_tls_client_auth[1-True-localhost-pyopenssl] _______________ [gw9] linux -- Python 3.13.1 /usr/bin/python3.13 self = conn = , method = 'GET' url = '/', body = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) timeout = Timeout(connect=0.1, read=0.1, total=None), chunked = False response_conn = preload_content = False, decode_content = False, enforce_content_length = True def _make_request( self, conn: BaseHTTPConnection, method: str, url: str, body: _TYPE_BODY | None = None, headers: typing.Mapping[str, str] | None = None, retries: Retry | None = None, timeout: _TYPE_TIMEOUT = _DEFAULT_TIMEOUT, chunked: bool = False, response_conn: BaseHTTPConnection | None = None, preload_content: bool = True, decode_content: bool = True, enforce_content_length: bool = True, ) -> BaseHTTPResponse: """ Perform a request on a given urllib connection object taken from our pool. :param conn: a connection from one of our connection pools :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param response_conn: Set this to ``None`` if you will handle releasing the connection or set the connection to have the response release it. :param preload_content: If True, the response's body will be preloaded during construction. :param decode_content: If True, will attempt to decode the body based on the 'content-encoding' header. :param enforce_content_length: Enforce content length checking. Body returned by server must match value of Content-Length header, if present. Otherwise, raise error. """ self.num_requests += 1 timeout_obj = self._get_timeout(timeout) timeout_obj.start_connect() conn.timeout = Timeout.resolve_default_timeout(timeout_obj.connect_timeout) try: # Trigger any extra validation we need to do. try: > self._validate_conn(conn) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=57321): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:466: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:1095: in _validate_conn conn.connect() __class__ = conn = self = /usr/lib/python3/dist-packages/urllib3/connection.py:730: in connect sock_and_verified = _ssl_wrap_socket_and_match_hostname( is_time_off = False probe_http2_host = '127.0.0.1' probe_http2_port = 57321 self = server_hostname = '127.0.0.1' server_hostname_rm_dot = '127.0.0.1' sock = target_supports_http2 = False tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/connection.py:909: in _ssl_wrap_socket_and_match_hostname ssl_sock = ssl_wrap_socket( assert_fingerprint = None assert_hostname = None ca_cert_data = None ca_cert_dir = None ca_certs = '/tmp/tmp30vz7842.pem' cert_file = '/tmp/tmp3atr44fs.pem' cert_reqs = 'CERT_REQUIRED' context = default_ssl_context = True key_file = None key_password = None normalized = '127.0.0.1' server_hostname = '127.0.0.1' sock = ssl_context = None ssl_maximum_version = None ssl_minimum_version = None ssl_version = None tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/util/ssl_.py:469: in ssl_wrap_socket ssl_sock = _ssl_wrap_socket_impl(sock, context, tls_in_tls, server_hostname) ca_cert_data = None ca_cert_dir = None ca_certs = '/tmp/tmp30vz7842.pem' cert_reqs = None certfile = '/tmp/tmp3atr44fs.pem' ciphers = None context = key_password = None keyfile = None server_hostname = '127.0.0.1' sock = ssl_context = ssl_version = None tls_in_tls = False /usr/lib/python3/dist-packages/urllib3/util/ssl_.py:513: in _ssl_wrap_socket_impl return ssl_context.wrap_socket(sock, server_hostname=server_hostname) server_hostname = '127.0.0.1' sock = ssl_context = tls_in_tls = False /usr/lib/python3.13/ssl.py:455: in wrap_socket return self.sslsocket_class._create( do_handshake_on_connect = True self = server_hostname = '127.0.0.1' server_side = False session = None sock = suppress_ragged_eofs = True /usr/lib/python3.13/ssl.py:1076: in _create self.do_handshake() __class__ = cls = connected = True context = do_handshake_on_connect = True kwargs = {'family': , 'fileno': 16, 'proto': 6, 'type': } self = server_hostname = '127.0.0.1' server_side = False session = None sock = sock_timeout = 0.1 suppress_ragged_eofs = True timeout = 0.1 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , block = False @_sslcopydoc def do_handshake(self, block=False): self._check_connected() timeout = self.gettimeout() try: if timeout == 0.0 and block: self.settimeout(None) > self._sslobj.do_handshake() E TimeoutError: _ssl.c:1001: The handshake operation timed out block = False self = timeout = 0.1 /usr/lib/python3.13/ssl.py:1372: TimeoutError The above exception was the direct cause of the following exception: self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmp30vz7842.pem', cert = '/tmp/tmp3atr44fs.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: > resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) cert = '/tmp/tmp3atr44fs.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmp30vz7842.pem' /usr/lib/python3/dist-packages/requests/adapters.py:667: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:843: in urlopen retries = retries.increment( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=57321): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/util/retry.py:474: in increment raise reraise(type(error), error, _stacktrace) _pool = _stacktrace = cause = 'unknown' connect = None error = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=57321): Read timed out. (read timeout=0.1)") method = 'GET' other = None read = False redirect = None redirect_location = None response = None self = Retry(total=0, connect=None, read=False, redirect=None, status=None) status = None status_count = None total = -1 url = '/' /usr/lib/python3/dist-packages/urllib3/util/util.py:39: in reraise raise value tb = None tp = value = None /usr/lib/python3/dist-packages/urllib3/connectionpool.py:789: in urlopen response = self._make_request( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=57321): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:490: in _make_request raise new_e body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=57321): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:468: in _make_request self._raise_timeout(err=e, url=url, timeout_value=conn.timeout) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=57321): Read timed out. (read timeout=0.1)") preload_content = False response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = err = TimeoutError('_ssl.c:1001: The handshake operation timed out'), url = '/' timeout_value = 0.1 def _raise_timeout( self, err: BaseSSLError | OSError | SocketTimeout, url: str, timeout_value: _TYPE_TIMEOUT | None, ) -> None: """Is the error actually a timeout? Will raise a ReadTimeout or pass""" if isinstance(err, SocketTimeout): > raise ReadTimeoutError( self, url, f"Read timed out. (read timeout={timeout_value})" ) from err E urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='127.0.0.1', port=57321): Read timed out. (read timeout=0.1) err = TimeoutError('_ssl.c:1001: The handshake operation timed out') self = timeout_value = 0.1 url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:369: ReadTimeoutError During handling of the above exception, another exception occurred: http_request_timeout = 0.1 mocker = tls_http_server = functools.partial(, request=>) adapter_type = 'pyopenssl', ca = tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmpcljyn8uy.pem' tls_certificate_private_key_pem_path = '/tmp/tmpu24c1hlc.pem' tls_ca_certificate_pem_path = '/tmp/tmp30vz7842.pem', is_trusted_cert = True tls_client_identity = 'localhost' tls_verify_mode = @pytest.mark.parametrize( # noqa: C901 # FIXME 'adapter_type', ( 'builtin', 'pyopenssl', ), ) @pytest.mark.parametrize( ('is_trusted_cert', 'tls_client_identity'), ( (True, 'localhost'), (True, '127.0.0.1'), (True, '*.localhost'), (True, 'not_localhost'), (False, 'localhost'), ), ) @pytest.mark.parametrize( 'tls_verify_mode', ( ssl.CERT_NONE, # server shouldn't validate client cert ssl.CERT_OPTIONAL, # same as CERT_REQUIRED in client mode, don't use ssl.CERT_REQUIRED, # server should validate if client cert CA is OK ), ) @pytest.mark.xfail( IS_PYPY and IS_CI, reason='Fails under PyPy in CI for unknown reason', strict=False, ) def test_tls_client_auth( # noqa: C901, WPS213 # FIXME # FIXME: remove twisted logic, separate tests http_request_timeout, mocker, tls_http_server, adapter_type, ca, tls_certificate, tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, tls_ca_certificate_pem_path, is_trusted_cert, tls_client_identity, tls_verify_mode, ): """Verify that client TLS certificate auth works correctly.""" test_cert_rejection = ( tls_verify_mode != ssl.CERT_NONE and not is_trusted_cert ) interface, _host, port = _get_conn_data(ANY_INTERFACE_IPV4) client_cert_root_ca = ca if is_trusted_cert else trustme.CA() with mocker.mock_module.patch( 'idna.core.ulabel', return_value=ntob(tls_client_identity), ): client_cert = client_cert_root_ca.issue_cert( ntou(tls_client_identity), ) del client_cert_root_ca with client_cert.private_key_and_cert_chain_pem.tempfile() as cl_pem: tls_adapter_cls = get_ssl_adapter_class(name=adapter_type) tls_adapter = tls_adapter_cls( tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, ) if adapter_type == 'pyopenssl': tls_adapter.context = tls_adapter.get_context() tls_adapter.context.set_verify( _stdlib_to_openssl_verify[tls_verify_mode], lambda conn, cert, errno, depth, preverify_ok: preverify_ok, ) else: tls_adapter.context.verify_mode = tls_verify_mode ca.configure_trust(tls_adapter.context) tls_certificate.configure_cert(tls_adapter.context) tlshttpserver = tls_http_server((interface, port), tls_adapter) interface, _host, port = _get_conn_data(tlshttpserver.bind_addr) make_https_request = functools.partial( requests.get, 'https://{host!s}:{port!s}/'.format(host=interface, port=port), # Don't wait for the first byte forever: timeout=http_request_timeout, # Server TLS certificate verification: verify=tls_ca_certificate_pem_path, # Client TLS certificate verification: cert=cl_pem, ) if not test_cert_rejection: > resp = make_https_request() _host = '127.0.0.1' adapter_type = 'pyopenssl' ca = cl_pem = '/tmp/tmp3atr44fs.pem' client_cert = http_request_timeout = 0.1 interface = '127.0.0.1' is_trusted_cert = True make_https_request = functools.partial(, 'https://127.0.0.1:57321/', timeout=0.1, verify='/tmp/tmp30vz7842.pem', cert='/tmp/tmp3atr44fs.pem') mocker = port = 57321 test_cert_rejection = False tls_adapter = tls_adapter_cls = tls_ca_certificate_pem_path = '/tmp/tmp30vz7842.pem' tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmpcljyn8uy.pem' tls_certificate_private_key_pem_path = '/tmp/tmpu24c1hlc.pem' tls_client_identity = 'localhost' tls_http_server = functools.partial(, request=>) tls_verify_mode = tlshttpserver = cheroot/test/test_ssl.py:328: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/requests/api.py:73: in get return request("get", url, params=params, **kwargs) kwargs = {'cert': '/tmp/tmp3atr44fs.pem', 'timeout': 0.1, 'verify': '/tmp/tmp30vz7842.pem'} params = None url = 'https://127.0.0.1:57321/' /usr/lib/python3/dist-packages/requests/api.py:59: in request return session.request(method=method, url=url, **kwargs) kwargs = {'cert': '/tmp/tmp3atr44fs.pem', 'params': None, 'timeout': 0.1, 'verify': '/tmp/tmp30vz7842.pem'} method = 'get' session = url = 'https://127.0.0.1:57321/' /usr/lib/python3/dist-packages/requests/sessions.py:589: in request resp = self.send(prep, **send_kwargs) allow_redirects = True auth = None cert = '/tmp/tmp3atr44fs.pem' cookies = None data = None files = None headers = None hooks = None json = None method = 'get' params = None prep = proxies = {'no': 'localhost'} req = self = send_kwargs = {'allow_redirects': True, 'cert': '/tmp/tmp3atr44fs.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, ...} settings = {'cert': '/tmp/tmp3atr44fs.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'verify': '/tmp/tmp30vz7842.pem'} stream = None timeout = 0.1 url = 'https://127.0.0.1:57321/' verify = '/tmp/tmp30vz7842.pem' /usr/lib/python3/dist-packages/requests/sessions.py:703: in send r = adapter.send(request, **kwargs) adapter = allow_redirects = True hooks = {'response': []} kwargs = {'cert': '/tmp/tmp3atr44fs.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'timeout': 0.1, ...} request = self = start = 1733986034.7266068 stream = False _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmp30vz7842.pem', cert = '/tmp/tmp3atr44fs.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) except (ProtocolError, OSError) as err: raise ConnectionError(err, request=request) except MaxRetryError as e: if isinstance(e.reason, ConnectTimeoutError): # TODO: Remove this in 3.0.0: see #2811 if not isinstance(e.reason, NewConnectionError): raise ConnectTimeout(e, request=request) if isinstance(e.reason, ResponseError): raise RetryError(e, request=request) if isinstance(e.reason, _ProxyError): raise ProxyError(e, request=request) if isinstance(e.reason, _SSLError): # This branch is for urllib3 v1.22 and later. raise SSLError(e, request=request) raise ConnectionError(e, request=request) except ClosedPoolError as e: raise ConnectionError(e, request=request) except _ProxyError as e: raise ProxyError(e) except (_SSLError, _HTTPError) as e: if isinstance(e, _SSLError): # This branch is for urllib3 versions earlier than v1.22 raise SSLError(e, request=request) elif isinstance(e, ReadTimeoutError): > raise ReadTimeout(e, request=request) E requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='127.0.0.1', port=57321): Read timed out. (read timeout=0.1) cert = '/tmp/tmp3atr44fs.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmp30vz7842.pem' /usr/lib/python3/dist-packages/requests/adapters.py:713: ReadTimeout _______________ test_tls_client_auth[0-True-127.0.0.1-pyopenssl] _______________ [gw10] linux -- Python 3.13.1 /usr/bin/python3.13 self = conn = , method = 'GET' url = '/', body = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) timeout = Timeout(connect=0.1, read=0.1, total=None), chunked = False response_conn = preload_content = False, decode_content = False, enforce_content_length = True def _make_request( self, conn: BaseHTTPConnection, method: str, url: str, body: _TYPE_BODY | None = None, headers: typing.Mapping[str, str] | None = None, retries: Retry | None = None, timeout: _TYPE_TIMEOUT = _DEFAULT_TIMEOUT, chunked: bool = False, response_conn: BaseHTTPConnection | None = None, preload_content: bool = True, decode_content: bool = True, enforce_content_length: bool = True, ) -> BaseHTTPResponse: """ Perform a request on a given urllib connection object taken from our pool. :param conn: a connection from one of our connection pools :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param response_conn: Set this to ``None`` if you will handle releasing the connection or set the connection to have the response release it. :param preload_content: If True, the response's body will be preloaded during construction. :param decode_content: If True, will attempt to decode the body based on the 'content-encoding' header. :param enforce_content_length: Enforce content length checking. Body returned by server must match value of Content-Length header, if present. Otherwise, raise error. """ self.num_requests += 1 timeout_obj = self._get_timeout(timeout) timeout_obj.start_connect() conn.timeout = Timeout.resolve_default_timeout(timeout_obj.connect_timeout) try: # Trigger any extra validation we need to do. try: self._validate_conn(conn) except (SocketTimeout, BaseSSLError) as e: self._raise_timeout(err=e, url=url, timeout_value=conn.timeout) raise # _validate_conn() starts the connection to an HTTPS proxy # so we need to wrap errors with 'ProxyError' here too. except ( OSError, NewConnectionError, TimeoutError, BaseSSLError, CertificateError, SSLError, ) as e: new_e: Exception = e if isinstance(e, (BaseSSLError, CertificateError)): new_e = SSLError(e) # If the connection didn't successfully connect to it's proxy # then there if isinstance( new_e, (OSError, NewConnectionError, TimeoutError, SSLError) ) and (conn and conn.proxy and not conn.has_connected_to_proxy): new_e = _wrap_proxy_error(new_e, conn.proxy.scheme) raise new_e # conn.request() calls http.client.*.request, not the method in # urllib3.request. It also calls makefile (recv) on the socket. try: conn.request( method, url, body=body, headers=headers, chunked=chunked, preload_content=preload_content, decode_content=decode_content, enforce_content_length=enforce_content_length, ) # We are swallowing BrokenPipeError (errno.EPIPE) since the server is # legitimately able to close the connection after sending a valid response. # With this behaviour, the received response is still readable. except BrokenPipeError: pass except OSError as e: # MacOS/Linux # EPROTOTYPE and ECONNRESET are needed on macOS # https://erickt.github.io/blog/2014/11/19/adventures-in-debugging-a-potential-osx-kernel-bug/ # Condition changed later to emit ECONNRESET instead of only EPROTOTYPE. if e.errno != errno.EPROTOTYPE and e.errno != errno.ECONNRESET: raise # Reset the timeout for the recv() on the socket read_timeout = timeout_obj.read_timeout if not conn.is_closed: # In Python 3 socket.py will catch EAGAIN and return None when you # try and read into the file pointer created by http.client, which # instead raises a BadStatusLine exception. Instead of catching # the exception and assuming all BadStatusLine exceptions are read # timeouts, check for a zero timeout before making the request. if read_timeout == 0: raise ReadTimeoutError( self, url, f"Read timed out. (read timeout={read_timeout})" ) conn.timeout = read_timeout # Receive the response from the server try: > response = conn.getresponse() body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' preload_content = False read_timeout = 0.1 response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:536: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connection.py:507: in getresponse httplib_response = super().getresponse() HTTPResponse = __class__ = resp_options = _ResponseOptions(request_method='GET', request_url='/', preload_content=False, decode_content=False, enforce_content_length=True) self = /usr/lib/python3.13/http/client.py:1428: in getresponse response.begin() response = self = /usr/lib/python3.13/http/client.py:331: in begin version, status, reason = self._read_status() self = /usr/lib/python3.13/http/client.py:292: in _read_status line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1") self = /usr/lib/python3.13/socket.py:719: in readinto return self._sock.recv_into(b) b = self = /usr/lib/python3.13/ssl.py:1304: in recv_into return self.read(nbytes, buffer) __class__ = buffer = flags = 0 nbytes = 8192 self = view = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , len = 8192 buffer = def read(self, len=1024, buffer=None): """Read up to LEN bytes and return them. Return zero-length string on EOF.""" self._checkClosed() if self._sslobj is None: raise ValueError("Read on closed or unwrapped SSL socket.") try: if buffer is not None: > return self._sslobj.read(len, buffer) E TimeoutError: The read operation timed out buffer = len = 8192 self = /usr/lib/python3.13/ssl.py:1138: TimeoutError The above exception was the direct cause of the following exception: self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmpt3nolj1b.pem', cert = '/tmp/tmpglyru4v5.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: > resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) cert = '/tmp/tmpglyru4v5.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmpt3nolj1b.pem' /usr/lib/python3/dist-packages/requests/adapters.py:667: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/connectionpool.py:843: in urlopen retries = retries.increment( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=39257): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/util/retry.py:474: in increment raise reraise(type(error), error, _stacktrace) _pool = _stacktrace = cause = 'unknown' connect = None error = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=39257): Read timed out. (read timeout=0.1)") method = 'GET' other = None read = False redirect = None redirect_location = None response = None self = Retry(total=0, connect=None, read=False, redirect=None, status=None) status = None status_count = None total = -1 url = '/' /usr/lib/python3/dist-packages/urllib3/util/util.py:39: in reraise raise value tb = None tp = value = None /usr/lib/python3/dist-packages/urllib3/connectionpool.py:789: in urlopen response = self._make_request( assert_same_host = False body = None body_pos = None chunked = False clean_exit = False conn = None decode_content = False destination_scheme = None err = None headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} http_tunnel_required = False method = 'GET' new_e = ReadTimeoutError("HTTPSConnectionPool(host='127.0.0.1', port=39257): Read timed out. (read timeout=0.1)") parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/', query=None, fragment=None) pool_timeout = None preload_content = False redirect = False release_conn = False release_this_conn = True response_conn = response_kw = {} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:538: in _make_request self._raise_timeout(err=e, url=url, timeout_value=read_timeout) body = None chunked = False conn = decode_content = False enforce_content_length = True headers = {'User-Agent': 'python-requests/2.32.3', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive'} method = 'GET' preload_content = False read_timeout = 0.1 response_conn = retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) self = timeout = Timeout(connect=0.1, read=0.1, total=None) timeout_obj = Timeout(connect=0.1, read=0.1, total=None) url = '/' _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = err = TimeoutError('The read operation timed out'), url = '/' timeout_value = 0.1 def _raise_timeout( self, err: BaseSSLError | OSError | SocketTimeout, url: str, timeout_value: _TYPE_TIMEOUT | None, ) -> None: """Is the error actually a timeout? Will raise a ReadTimeout or pass""" if isinstance(err, SocketTimeout): > raise ReadTimeoutError( self, url, f"Read timed out. (read timeout={timeout_value})" ) from err E urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='127.0.0.1', port=39257): Read timed out. (read timeout=0.1) err = TimeoutError('The read operation timed out') self = timeout_value = 0.1 url = '/' /usr/lib/python3/dist-packages/urllib3/connectionpool.py:369: ReadTimeoutError During handling of the above exception, another exception occurred: http_request_timeout = 0.1 mocker = tls_http_server = functools.partial(, request=>) adapter_type = 'pyopenssl', ca = tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmp2ovn4eqr.pem' tls_certificate_private_key_pem_path = '/tmp/tmpn84spte0.pem' tls_ca_certificate_pem_path = '/tmp/tmpt3nolj1b.pem', is_trusted_cert = True tls_client_identity = '127.0.0.1', tls_verify_mode = @pytest.mark.parametrize( # noqa: C901 # FIXME 'adapter_type', ( 'builtin', 'pyopenssl', ), ) @pytest.mark.parametrize( ('is_trusted_cert', 'tls_client_identity'), ( (True, 'localhost'), (True, '127.0.0.1'), (True, '*.localhost'), (True, 'not_localhost'), (False, 'localhost'), ), ) @pytest.mark.parametrize( 'tls_verify_mode', ( ssl.CERT_NONE, # server shouldn't validate client cert ssl.CERT_OPTIONAL, # same as CERT_REQUIRED in client mode, don't use ssl.CERT_REQUIRED, # server should validate if client cert CA is OK ), ) @pytest.mark.xfail( IS_PYPY and IS_CI, reason='Fails under PyPy in CI for unknown reason', strict=False, ) def test_tls_client_auth( # noqa: C901, WPS213 # FIXME # FIXME: remove twisted logic, separate tests http_request_timeout, mocker, tls_http_server, adapter_type, ca, tls_certificate, tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, tls_ca_certificate_pem_path, is_trusted_cert, tls_client_identity, tls_verify_mode, ): """Verify that client TLS certificate auth works correctly.""" test_cert_rejection = ( tls_verify_mode != ssl.CERT_NONE and not is_trusted_cert ) interface, _host, port = _get_conn_data(ANY_INTERFACE_IPV4) client_cert_root_ca = ca if is_trusted_cert else trustme.CA() with mocker.mock_module.patch( 'idna.core.ulabel', return_value=ntob(tls_client_identity), ): client_cert = client_cert_root_ca.issue_cert( ntou(tls_client_identity), ) del client_cert_root_ca with client_cert.private_key_and_cert_chain_pem.tempfile() as cl_pem: tls_adapter_cls = get_ssl_adapter_class(name=adapter_type) tls_adapter = tls_adapter_cls( tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, ) if adapter_type == 'pyopenssl': tls_adapter.context = tls_adapter.get_context() tls_adapter.context.set_verify( _stdlib_to_openssl_verify[tls_verify_mode], lambda conn, cert, errno, depth, preverify_ok: preverify_ok, ) else: tls_adapter.context.verify_mode = tls_verify_mode ca.configure_trust(tls_adapter.context) tls_certificate.configure_cert(tls_adapter.context) tlshttpserver = tls_http_server((interface, port), tls_adapter) interface, _host, port = _get_conn_data(tlshttpserver.bind_addr) make_https_request = functools.partial( requests.get, 'https://{host!s}:{port!s}/'.format(host=interface, port=port), # Don't wait for the first byte forever: timeout=http_request_timeout, # Server TLS certificate verification: verify=tls_ca_certificate_pem_path, # Client TLS certificate verification: cert=cl_pem, ) if not test_cert_rejection: > resp = make_https_request() _host = '127.0.0.1' adapter_type = 'pyopenssl' ca = cl_pem = '/tmp/tmpglyru4v5.pem' client_cert = http_request_timeout = 0.1 interface = '127.0.0.1' is_trusted_cert = True make_https_request = functools.partial(, 'https://127.0.0.1:39257/', timeout=0.1, verify='/tmp/tmpt3nolj1b.pem', cert='/tmp/tmpglyru4v5.pem') mocker = port = 39257 test_cert_rejection = False tls_adapter = tls_adapter_cls = tls_ca_certificate_pem_path = '/tmp/tmpt3nolj1b.pem' tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmp2ovn4eqr.pem' tls_certificate_private_key_pem_path = '/tmp/tmpn84spte0.pem' tls_client_identity = '127.0.0.1' tls_http_server = functools.partial(, request=>) tls_verify_mode = tlshttpserver = cheroot/test/test_ssl.py:328: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/requests/api.py:73: in get return request("get", url, params=params, **kwargs) kwargs = {'cert': '/tmp/tmpglyru4v5.pem', 'timeout': 0.1, 'verify': '/tmp/tmpt3nolj1b.pem'} params = None url = 'https://127.0.0.1:39257/' /usr/lib/python3/dist-packages/requests/api.py:59: in request return session.request(method=method, url=url, **kwargs) kwargs = {'cert': '/tmp/tmpglyru4v5.pem', 'params': None, 'timeout': 0.1, 'verify': '/tmp/tmpt3nolj1b.pem'} method = 'get' session = url = 'https://127.0.0.1:39257/' /usr/lib/python3/dist-packages/requests/sessions.py:589: in request resp = self.send(prep, **send_kwargs) allow_redirects = True auth = None cert = '/tmp/tmpglyru4v5.pem' cookies = None data = None files = None headers = None hooks = None json = None method = 'get' params = None prep = proxies = {'no': 'localhost'} req = self = send_kwargs = {'allow_redirects': True, 'cert': '/tmp/tmpglyru4v5.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, ...} settings = {'cert': '/tmp/tmpglyru4v5.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'verify': '/tmp/tmpt3nolj1b.pem'} stream = None timeout = 0.1 url = 'https://127.0.0.1:39257/' verify = '/tmp/tmpt3nolj1b.pem' /usr/lib/python3/dist-packages/requests/sessions.py:703: in send r = adapter.send(request, **kwargs) adapter = allow_redirects = True hooks = {'response': []} kwargs = {'cert': '/tmp/tmpglyru4v5.pem', 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'timeout': 0.1, ...} request = self = start = 1733986037.1199508 stream = False _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = request = , stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) verify = '/tmp/tmpt3nolj1b.pem', cert = '/tmp/tmpglyru4v5.pem' proxies = OrderedDict({'no': 'localhost'}) def send( self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None ): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection_with_tls_context( request, verify, proxies=proxies, cert=cert ) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers( request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies, ) chunked = not (request.body is None or "Content-Length" in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError: raise ValueError( f"Invalid timeout {timeout}. Pass a (connect, read) timeout tuple, " f"or a single float to set both timeouts to the same value." ) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout, chunked=chunked, ) except (ProtocolError, OSError) as err: raise ConnectionError(err, request=request) except MaxRetryError as e: if isinstance(e.reason, ConnectTimeoutError): # TODO: Remove this in 3.0.0: see #2811 if not isinstance(e.reason, NewConnectionError): raise ConnectTimeout(e, request=request) if isinstance(e.reason, ResponseError): raise RetryError(e, request=request) if isinstance(e.reason, _ProxyError): raise ProxyError(e, request=request) if isinstance(e.reason, _SSLError): # This branch is for urllib3 v1.22 and later. raise SSLError(e, request=request) raise ConnectionError(e, request=request) except ClosedPoolError as e: raise ConnectionError(e, request=request) except _ProxyError as e: raise ProxyError(e) except (_SSLError, _HTTPError) as e: if isinstance(e, _SSLError): # This branch is for urllib3 versions earlier than v1.22 raise SSLError(e, request=request) elif isinstance(e, ReadTimeoutError): > raise ReadTimeout(e, request=request) E requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='127.0.0.1', port=39257): Read timed out. (read timeout=0.1) cert = '/tmp/tmpglyru4v5.pem' chunked = False conn = proxies = OrderedDict({'no': 'localhost'}) request = self = stream = False timeout = Timeout(connect=0.1, read=0.1, total=None) url = '/' verify = '/tmp/tmpt3nolj1b.pem' /usr/lib/python3/dist-packages/requests/adapters.py:713: ReadTimeout ________________________ test_ssl_env[1-False-builtin] _________________________ [gw0] linux -- Python 3.13.1 /usr/bin/python3.13 self = @contextmanager def _error_catcher(self) -> typing.Generator[None, None, None]: """ Catch low-level python exceptions, instead re-raising urllib3 variants, so that low-level exceptions are not leaked in the high-level api. On exit, release the connection back to the pool. """ clean_exit = False try: try: > yield clean_exit = False self = /usr/lib/python3/dist-packages/urllib3/response.py:748: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/response.py:1206: in read_chunked self._update_chunk_length() amt = 10240 decode_content = True self = /usr/lib/python3/dist-packages/urllib3/response.py:1125: in _update_chunk_length line = self._fp.fp.readline() # type: ignore[union-attr] self = /usr/lib/python3.13/socket.py:719: in readinto return self._sock.recv_into(b) b = self = /usr/lib/python3.13/ssl.py:1304: in recv_into return self.read(nbytes, buffer) __class__ = buffer = flags = 0 nbytes = 8192 self = view = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = , len = 8192 buffer = def read(self, len=1024, buffer=None): """Read up to LEN bytes and return them. Return zero-length string on EOF.""" self._checkClosed() if self._sslobj is None: raise ValueError("Read on closed or unwrapped SSL socket.") try: if buffer is not None: > return self._sslobj.read(len, buffer) E TimeoutError: The read operation timed out buffer = len = 8192 self = /usr/lib/python3.13/ssl.py:1138: TimeoutError The above exception was the direct cause of the following exception: def generate(): # Special case for urllib3. if hasattr(self.raw, "stream"): try: > yield from self.raw.stream(chunk_size, decode_content=True) chunk_size = 10240 self = /usr/lib/python3/dist-packages/requests/models.py:820: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/urllib3/response.py:1057: in stream yield from self.read_chunked(amt, decode_content=decode_content) amt = 10240 decode_content = True self = /usr/lib/python3/dist-packages/urllib3/response.py:1189: in read_chunked with self._error_catcher(): amt = 10240 decode_content = True self = /usr/lib/python3.13/contextlib.py:162: in __exit__ self.gen.throw(value) self = traceback = typ = value = TimeoutError('The read operation timed out') _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = @contextmanager def _error_catcher(self) -> typing.Generator[None, None, None]: """ Catch low-level python exceptions, instead re-raising urllib3 variants, so that low-level exceptions are not leaked in the high-level api. On exit, release the connection back to the pool. """ clean_exit = False try: try: yield except SocketTimeout as e: # FIXME: Ideally we'd like to include the url in the ReadTimeoutError but # there is yet no clean way to get at it from this context. > raise ReadTimeoutError(self._pool, None, "Read timed out.") from e # type: ignore[arg-type] E urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='127.0.0.1', port=53281): Read timed out. clean_exit = False self = /usr/lib/python3/dist-packages/urllib3/response.py:753: ReadTimeoutError During handling of the above exception, another exception occurred: thread_exceptions = [], recwarn = WarningsRecorder(record=True) mocker = http_request_timeout = 0.1 tls_http_server = functools.partial(, request=>) adapter_type = 'builtin', ca = tls_verify_mode = tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmprpyh72t9.pem' tls_certificate_private_key_pem_path = '/tmp/tmpw3lq7jpi.pem' tls_ca_certificate_pem_path = '/tmp/tmpnb0r_mwj.pem', use_client_cert = False @pytest.mark.parametrize( # noqa: C901 # FIXME 'adapter_type', ( pytest.param( 'builtin', marks=pytest.mark.xfail( IS_MACOS and PY310_PLUS, reason='Unclosed TLS resource warnings happen on macOS ' 'under Python 3.10 (#508)', strict=False, ), ), 'pyopenssl', ), ) @pytest.mark.parametrize( ('tls_verify_mode', 'use_client_cert'), ( (ssl.CERT_NONE, False), (ssl.CERT_NONE, True), (ssl.CERT_OPTIONAL, False), (ssl.CERT_OPTIONAL, True), (ssl.CERT_REQUIRED, True), ), ) def test_ssl_env( # noqa: C901 # FIXME thread_exceptions, recwarn, mocker, http_request_timeout, tls_http_server, adapter_type, ca, tls_verify_mode, tls_certificate, tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, tls_ca_certificate_pem_path, use_client_cert, ): """Test the SSL environment generated by the SSL adapters.""" interface, _host, port = _get_conn_data(ANY_INTERFACE_IPV4) with mocker.mock_module.patch( 'idna.core.ulabel', return_value=ntob('127.0.0.1'), ): client_cert = ca.issue_cert(ntou('127.0.0.1')) with client_cert.private_key_and_cert_chain_pem.tempfile() as cl_pem: tls_adapter_cls = get_ssl_adapter_class(name=adapter_type) tls_adapter = tls_adapter_cls( tls_certificate_chain_pem_path, tls_certificate_private_key_pem_path, ) if adapter_type == 'pyopenssl': tls_adapter.context = tls_adapter.get_context() tls_adapter.context.set_verify( _stdlib_to_openssl_verify[tls_verify_mode], lambda conn, cert, errno, depth, preverify_ok: preverify_ok, ) else: tls_adapter.context.verify_mode = tls_verify_mode ca.configure_trust(tls_adapter.context) tls_certificate.configure_cert(tls_adapter.context) tlswsgiserver = tls_http_server((interface, port), tls_adapter) interface, _host, port = _get_conn_data(tlswsgiserver.bind_addr) > resp = requests.get( 'https://' + interface + ':' + str(port) + '/env', timeout=http_request_timeout, verify=tls_ca_certificate_pem_path, cert=cl_pem if use_client_cert else None, ) _host = '127.0.0.1' adapter_type = 'builtin' ca = cl_pem = '/tmp/tmpriuedzsz.pem' client_cert = http_request_timeout = 0.1 interface = '127.0.0.1' mocker = port = 53281 recwarn = WarningsRecorder(record=True) thread_exceptions = [] tls_adapter = tls_adapter_cls = tls_ca_certificate_pem_path = '/tmp/tmpnb0r_mwj.pem' tls_certificate = tls_certificate_chain_pem_path = '/tmp/tmprpyh72t9.pem' tls_certificate_private_key_pem_path = '/tmp/tmpw3lq7jpi.pem' tls_http_server = functools.partial(, request=>) tls_verify_mode = tlswsgiserver = use_client_cert = False cheroot/test/test_ssl.py:507: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ /usr/lib/python3/dist-packages/requests/api.py:73: in get return request("get", url, params=params, **kwargs) kwargs = {'cert': None, 'timeout': 0.1, 'verify': '/tmp/tmpnb0r_mwj.pem'} params = None url = 'https://127.0.0.1:53281/env' /usr/lib/python3/dist-packages/requests/api.py:59: in request return session.request(method=method, url=url, **kwargs) kwargs = {'cert': None, 'params': None, 'timeout': 0.1, 'verify': '/tmp/tmpnb0r_mwj.pem'} method = 'get' session = url = 'https://127.0.0.1:53281/env' /usr/lib/python3/dist-packages/requests/sessions.py:589: in request resp = self.send(prep, **send_kwargs) allow_redirects = True auth = None cert = None cookies = None data = None files = None headers = None hooks = None json = None method = 'get' params = None prep = proxies = {'no': 'localhost'} req = self = send_kwargs = {'allow_redirects': True, 'cert': None, 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, ...} settings = {'cert': None, 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'verify': '/tmp/tmpnb0r_mwj.pem'} stream = None timeout = 0.1 url = 'https://127.0.0.1:53281/env' verify = '/tmp/tmpnb0r_mwj.pem' /usr/lib/python3/dist-packages/requests/sessions.py:746: in send r.content adapter = allow_redirects = True elapsed = 0.046224117279052734 gen = history = [] hooks = {'response': []} kwargs = {'cert': None, 'proxies': OrderedDict({'no': 'localhost'}), 'stream': False, 'timeout': 0.1, ...} r = request = self = start = 1733986039.8288696 stream = False /usr/lib/python3/dist-packages/requests/models.py:902: in content self._content = b"".join(self.iter_content(CONTENT_CHUNK_SIZE)) or b"" self = _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ def generate(): # Special case for urllib3. if hasattr(self.raw, "stream"): try: yield from self.raw.stream(chunk_size, decode_content=True) except ProtocolError as e: raise ChunkedEncodingError(e) except DecodeError as e: raise ContentDecodingError(e) except ReadTimeoutError as e: > raise ConnectionError(e) E requests.exceptions.ConnectionError: HTTPSConnectionPool(host='127.0.0.1', port=53281): Read timed out. chunk_size = 10240 self = /usr/lib/python3/dist-packages/requests/models.py:826: ConnectionError ----------------------------- Captured stdout call ----------------------------- {'ACTUAL_SERVER_PROTOCOL': 'HTTP/1.1', 'PATH_INFO': '/env', 'QUERY_STRING': '', 'REMOTE_ADDR': '127.0.0.1', 'REMOTE_PORT': '36530', 'REQUEST_METHOD': 'GET', 'REQUEST_URI': '/env', 'SCRIPT_NAME': '', 'SERVER_NAME': 'Cheroot/10.0.1', 'SERVER_PROTOCOL': 'HTTP/1.1', 'SERVER_SOFTWARE': 'Cheroot/10.0.1 Server', 'wsgi.input_terminated': False, 'wsgi.multiprocess': False, 'wsgi.multithread': True, 'wsgi.run_once': False, 'wsgi.url_scheme': 'https', 'wsgi.version': (1, 0), 'SERVER_PORT': '53281', 'HTTP_HOST': '127.0.0.1:53281', 'HTTP_USER_AGENT': 'python-requests/2.32.3', 'HTTP_ACCEPT_ENCODING': 'gzip, deflate', 'HTTP_ACCEPT': '*/*', 'HTTP_CONNECTION': 'keep-alive', 'HTTPS': 'on', 'SSL_PROTOCOL': 'TLSv1.3', 'SSL_CIPHER': 'TLS_AES_256_GCM_SHA384', 'SSL_CIPHER_EXPORT': '', 'SSL_CIPHER_USEKEYSIZE': 256, 'SSL_VERSION_INTERFACE': 'Cheroot/10.0.1 Python/3.13.1 (main, Dec 4 2024, 09:39:10) [GCC 14.2.0]', 'SSL_VERSION_LIBRARY': 'OpenSSL 3.3.2 3 Sep 2024', 'SSL_CLIENT_VERIFY': 'NONE', 'SSL_SESSION_ID': 'b5b25aad56da88e006959d36c97717bef7966abbf7d24f25a83dd1bcb6f78e11', 'SSL_CIPHER_ALGKEYSIZE': 256, 'SSL_TLS_SNI': None, 'SSL_SERVER_M_VERSION': '3', 'SSL_SERVER_M_SERIAL': '5325C560C14D376758F64689CE671DC727A7F678', 'SSL_SERVER_V_START': 'Jan 1 00:00:00 2000 GMT', 'SSL_SERVER_V_END': 'Jan 1 00:00:00 3000 GMT', 'SSL_SERVER_S_DN': 'O=trustme v1.2.0,OU=Testing cert #PGbpeJXALVuHmFmY', 'SSL_SERVER_S_DN_O': 'trustme v1.2.0', 'SSL_SERVER_S_DN_OU': 'Testing cert #PGbpeJXALVuHmFmY', 'SSL_SERVER_I_DN': 'O=trustme v1.2.0,OU=Testing CA #xiSR7oPXwEFiIPjD', 'SSL_SERVER_I_DN_O': 'trustme v1.2.0', 'SSL_SERVER_I_DN_OU': 'Testing CA #xiSR7oPXwEFiIPjD', 'SSL_SERVER_V_REMAIN': '365243', 'SSL_SERVER_CERT': '-----BEGIN CERTIFICATE-----\nMIICKDCCAc6gAwIBAgIUUyXFYMFNN2dY9kaJzmcdxyen9ngwCgYIKoZIzj0EAwIw\nQDEXMBUGA1UECgwOdHJ1c3RtZSB2MS4yLjAxJTAjBgNVBAsMHFRlc3RpbmcgQ0Eg\nI3hpU1I3b1BYd0VGaUlQakQwIBcNMDAwMTAxMDAwMDAwWhgPMzAwMDAxMDEwMDAw\nMDBaMEIxFzAVBgNVBAoMDnRydXN0bWUgdjEuMi4wMScwJQYDVQQLDB5UZXN0aW5n\nIGNlcnQgI1BHYnBlSlhBTFZ1SG1GbVkwWTATBgcqhkjOPQIBBggqhkjOPQMBBwNC\nAAREFaegSCIdHI56UAwSBKLuMF7yx8xGDMZ2FgipsFPQgcl2UEsgbXbIqfqxZrQq\nhx3vYE3fzCv3muKvYHjYXZzSo4GhMIGeMB0GA1UdDgQWBBS1zADWzkDkEL2JSPoN\n5jIlViliUTAMBgNVHRMBAf8EAjAAMB8GA1UdIwQYMBaAFIaRfhVeFfbuAI45qt8X\n6BP4gGvFMBIGA1UdEQEB/wQIMAaHBH8AAAEwDgYDVR0PAQH/BAQDAgWgMCoGA1Ud\nJQEB/wQgMB4GCCsGAQUFBwMCBggrBgEFBQcDAQYIKwYBBQUHAwMwCgYIKoZIzj0E\nAwIDSAAwRQIhAJmvI104biegFX3alB21QeXc4XcyJMx2vcPgYM1SNG71AiB/pP+z\n3emogZK3kyvla48++gX+qY4V9lHw4aDydEnyLQ==\n-----END CERTIFICATE-----'} - generated xml file: /build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build/.test-results/pytest/test.xml - ---------- coverage: platform linux, python 3.13.1-final-0 ----------- Name Stmts Miss Cover Missing -------------------------------------------------------------- cheroot/__init__.py 10 10 0% 3-14 cheroot/__main__.py 3 3 0% 3-6 cheroot/_compat.py 35 2 94% 12-13 cheroot/cli.py 70 22 69% 86, 93, 101-107, 111, 119, 123-129, 150-151, 232-243 cheroot/connections.py 178 31 83% 17-39, 227, 284, 325, 339-344, 351-375 cheroot/errors.py 20 2 90% 55-56 cheroot/makefile.py 41 2 95% 20, 35 cheroot/server.py 1032 242 77% 120-127, 132-135, 139-144, 198, 204, 218, 229, 234, 251-252, 270, 281-284, 296-299, 323-332, 336, 340, 344-347, 374, 393-402, 414-423, 427, 431, 435-437, 465, 471, 480-481, 493, 501, 518, 522, 531-533, 547-578, 590-599, 608-629, 633, 716-721, 728-734, 768-770, 838-864, 907-911, 928-930, 937, 960-961, 1028-1030, 1059-1061, 1072-1078, 1110, 1150, 1283, 1328, 1355, 1357, 1393, 1397, 1408-1416, 1448, 1667-1670, 1674, 1721, 1735, 1740, 1759, 1764-1766, 1777-1785, 1792-1796, 1799, 1821-1822, 1870, 1903-1907, 1917, 1921-1927, 1937, 1951-1952, 1956-1958, 1965-1971, 1974, 1989, 1992, 1999, 2002-2005, 2055-2058, 2094-2096, 2146-2151, 2171-2173, 2217, 2225-2226 cheroot/ssl/builtin.py 191 28 85% 17-18, 22-26, 37, 73, 101-102, 127, 206, 218, 225, 233, 236, 289-290, 318, 365, 396, 406-407, 421, 430, 441-442 cheroot/ssl/pyopenssl.py 144 20 86% 65-68, 100, 105-108, 111, 116-117, 126, 130, 150, 158, 272, 283, 304, 378 cheroot/test/_pytest_plugin.py 6 4 33% 7-13, 16 cheroot/test/conftest.py 54 4 93% 29, 32, 55-56 cheroot/test/helper.py 99 42 58% 42-70, 75-76, 81-83, 88-91, 97-105, 135, 150-151, 166 cheroot/test/test_conn.py 719 34 95% 55, 97, 175-178, 306-311, 938, 1049-1053, 1077-1080, 1083, 1177, 1351-1364, 1477-1479 cheroot/test/test_core.py 220 7 97% 32, 296-298, 403-406, 439 cheroot/test/test_makefile.py 30 4 87% 24-27 cheroot/test/test_server.py 242 5 98% 54, 238, 265, 307, 408 cheroot/test/test_ssl.py 251 30 88% 89, 153-156, 338, 354, 358, 364-368, 378, 430, 551, 553-569, 574, 590-603, 637, 687, 691 cheroot/test/webtest.py 306 176 42% 54-57, 62-64, 72-79, 94-96, 125-126, 130-134, 145-150, 159, 163, 171, 198-228, 238-246, 251-296, 301, 305-310, 318-323, 327-338, 342-351, 355-362, 366-371, 375-381, 385-392, 396-401, 405-410, 414-419, 439, 451-454, 478, 502-505, 509, 518, 524, 579-588 cheroot/testing.py 88 9 90% 46-47, 147-149, 153, 165-167 cheroot/workers/threadpool.py 176 38 78% 26, 29, 163, 218-222, 305-310, 320, 336-352, 363-364, 394-395, 400-411, 426 cheroot/wsgi.py 144 33 77% 88, 92, 140, 163-164, 170, 174, 194, 271-282, 325-342, 396-402 -------------------------------------------------------------- TOTAL 4193 748 82% 8 files skipped due to complete coverage. Coverage XML written to file .test-results/pytest/cov.xml ============================= slowest 10 durations ============================= 39.80s call cheroot/test/test_wsgi.py::test_connection_keepalive 4.17s call cheroot/test/test_conn.py::test_HTTP11_Timeout_after_request 3.48s call cheroot/test/test_conn.py::test_keepalive_conn_management 2.51s call cheroot/test/test_conn.py::test_broken_connection_during_http_communication_fallback 2.29s call cheroot/test/test_ssl.py::test_tls_client_auth[2-True-127.0.0.1-pyopenssl] 2.21s setup cheroot/test/test_server.py::test_high_number_of_file_descriptors[2048] 2.11s call cheroot/test/test_ssl.py::test_tls_client_auth[1-True-*.localhost-builtin] 2.01s call cheroot/test/test_conn.py::test_HTTP11_Timeout[False] 2.00s call cheroot/test/test_conn.py::test_HTTP11_Timeout[True] 1.94s call cheroot/test/test_ssl.py::test_tls_client_auth[0-True-localhost-pyopenssl] =========================== short test summary info ============================ XFAIL cheroot/test/test_conn.py::test_Chunked_Encoding - Headers from earlier request leak into the request line for a subsequent request, resulting in 400 instead of 413. See cherrypy/cheroot#69 for details. XFAIL cheroot/test/test_conn.py::test_598 - Sometimes this test fails due to low timeout. Ref: https://github.com/cherrypy/cherrypy/issues/598 XFAIL cheroot/test/test_core.py::test_large_request - https://github.com/cherrypy/cheroot/issues/106 FAILED cheroot/test/test_ssl.py::test_ssl_adapters[builtin] - requests.except... FAILED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-*.localhost-pyopenssl] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[0-False-localhost-pyopenssl] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-not_localhost-builtin] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-not_localhost-pyopenssl] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-localhost-pyopenssl] FAILED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-127.0.0.1-pyopenssl] FAILED cheroot/test/test_ssl.py::test_ssl_env[1-False-builtin] - requests.exc... ========= 8 failed, 173 passed, 3 xfailed, 2 rerun in 86.93s (0:01:26) ========= E: pybuild pybuild:389: test: plugin pyproject failed with: exit code=1: cd /build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.13_cheroot/build; python3.13 -m pytest -k "not (test_https_over_http_error)" -n auto --pyargs cheroot.test I: pybuild base:311: cd /build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.12_cheroot/build; python3.12 -m pytest -k "not (test_https_over_http_error)" -n auto --pyargs cheroot.test ============================= test session starts ============================== platform linux -- Python 3.12.8, pytest-8.3.4, pluggy-1.5.0 -- /usr/bin/python3.12 cachedir: .pytest_cache rootdir: /build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.12_cheroot/build configfile: pytest.ini plugins: typeguard-4.4.1, xdist-3.6.1, cov-5.0.0, forked-1.6.0, rerunfailures-14.0, mock-3.14.0 created: 13/13 workers 13 workers [184 items] scheduling tests via LoadScheduling cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(EPIPE)] cheroot/test/test__compat.py::test_extract_bytes[qwerty-qwerty] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[foo@bar:5000-expected_bind_addr3] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[/tmp/cheroot.sock-/tmp/cheroot.sock] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(ESHUTDOWN)] cheroot/test/test_cli.py::test_Aplication_resolve[None-application] cheroot/test/test__compat.py::test_compat_functions_positive[ntob-bar-bar] cheroot/test/test__compat.py::test_compat_functions_negative_nonnative[ntob] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[192.168.1.1:80-expected_bind_addr0] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[ConnectionResetError(ECONNRESET)] [gw1] [ 0%] PASSED cheroot/test/test__compat.py::test_extract_bytes[qwerty-qwerty] cheroot/test/test__compat.py::test_extract_bytes[input_argument1-asdfgh] [gw1] [ 1%] PASSED cheroot/test/test__compat.py::test_extract_bytes[input_argument1-asdfgh] cheroot/test/test_conn.py::test_streaming_10[False] [gw4] [ 1%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[foo@bar:5000-expected_bind_addr3] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[foo-expected_bind_addr4] [gw4] [ 2%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[foo-expected_bind_addr4] [gw2] [ 2%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[192.168.1.1:80-expected_bind_addr0] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[[::1]:8000-expected_bind_addr1] [gw3] [ 3%] PASSED cheroot/test/test__compat.py::test_compat_functions_negative_nonnative[ntob] cheroot/test/test__compat.py::test_compat_functions_negative_nonnative[ntou] [gw3] [ 3%] PASSED cheroot/test/test__compat.py::test_compat_functions_negative_nonnative[ntou] [gw8] [ 4%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[/tmp/cheroot.sock-/tmp/cheroot.sock] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[/tmp/some-random-file-name-/tmp/some-random-file-name] [gw8] [ 4%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[/tmp/some-random-file-name-/tmp/some-random-file-name] cheroot/test/test_conn.py::test_keepalive[HTTP/1.1] [gw6] [ 5%] PASSED cheroot/test/test_cli.py::test_Aplication_resolve[None-application] cheroot/test/test_cli.py::test_Aplication_resolve[application-application] [gw6] [ 5%] PASSED cheroot/test/test_cli.py::test_Aplication_resolve[application-application] cheroot/test/test_conn.py::test_HTTP11_persistent_connections [gw0] [ 6%] PASSED cheroot/test/test__compat.py::test_compat_functions_positive[ntob-bar-bar] cheroot/test/test__compat.py::test_compat_functions_positive[ntou-bar-bar] [gw0] [ 7%] PASSED cheroot/test/test__compat.py::test_compat_functions_positive[ntou-bar-bar] [gw2] [ 7%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[[::1]:8000-expected_bind_addr1] [gw7] [ 8%] PASSED cheroot/test/test_conn.py::test_streaming_10[False] [gw9] [ 8%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(EPIPE)] [gw5] [ 9%] PASSED cheroot/test/test_conn.py::test_HTTP11_persistent_connections [gw10] [ 9%] PASSED cheroot/test/test_conn.py::test_keepalive[HTTP/1.1] [gw12] [ 10%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(ESHUTDOWN)] [gw11] [ 10%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[ConnectionResetError(ECONNRESET)] cheroot/test/test_conn.py::test_streaming_10[True] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[RuntimeError(666)] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[simulated socket.error(ENOTCONN)] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[BrokenPipeError(EPIPE)] cheroot/test/test_conn.py::test_keepalive_conn_management cheroot/test/test_conn.py::test_streaming_11[False] [gw7] [ 11%] PASSED cheroot/test/test_conn.py::test_streaming_10[True] cheroot/test/test__compat.py::test_extract_bytes_invalid cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[123456789-expected_bind_addr5] [gw1] [ 11%] PASSED cheroot/test/test__compat.py::test_extract_bytes_invalid [gw4] [ 12%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[123456789-expected_bind_addr5] cheroot/test/test_conn.py::test_broken_connection_during_http_communication_fallback cheroot/test/test_conn.py::test_HTTP11_Timeout[True] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[@cheroot-\x00cheroot] cheroot/test/test__compat.py::test_ntou_escape [gw3] [ 13%] PASSED cheroot/test/test__compat.py::test_ntou_escape [gw8] [ 13%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[@cheroot-\x00cheroot] cheroot/test/test_conn.py::test_Chunked_Encoding cheroot/test/test_conn.py::test_100_Continue cheroot/test/test_cli.py::test_Aplication_resolve[main-main] [gw6] [ 14%] PASSED cheroot/test/test_cli.py::test_Aplication_resolve[main-main] cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[localhost:5000-expected_bind_addr2] [gw12] [ 14%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[RuntimeError(666)] [gw11] [ 15%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[BrokenPipeError(EPIPE)] [gw9] [ 15%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[simulated socket.error(ENOTCONN)] cheroot/test/test__compat.py::test_compat_functions_positive[bton-bar-bar] [gw0] [ 16%] PASSED cheroot/test/test__compat.py::test_compat_functions_positive[bton-bar-bar] cheroot/test/test_core.py::test_normal_request [gw5] [ 16%] PASSED cheroot/test/test_conn.py::test_streaming_11[False] [gw2] [ 17%] PASSED cheroot/test/test_cli.py::test_parse_wsgi_bind_addr[localhost:5000-expected_bind_addr2] cheroot/test/test_conn.py::test_Content_Length_out[/wrong_cl_unbuffered-200-I too] cheroot/test/test_conn.py::test_No_CRLF[\r\n\n] cheroot/test/test_conn.py::test_keepalive[HTTP/1.0] [gw0] [ 17%] PASSED cheroot/test/test_core.py::test_normal_request [gw3] [ 18%] PASSED cheroot/test/test_conn.py::test_100_Continue [gw2] [ 19%] PASSED cheroot/test/test_conn.py::test_No_CRLF[\r\n\n] cheroot/test/test_core.py::test_query_string_request [gw6] [ 19%] PASSED cheroot/test/test_conn.py::test_Content_Length_out[/wrong_cl_unbuffered-200-I too] cheroot/test/test_conn.py::test_598 cheroot/test/test_conn.py::test_invalid_selected_connection cheroot/test/test_conn.py::test_streaming_11[True] cheroot/test/test_conn.py::test_readall_or_close[0] [gw3] [ 20%] PASSED cheroot/test/test_conn.py::test_readall_or_close[0] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(-1)] [gw1] [ 20%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_http_communication_fallback cheroot/test/test_conn.py::test_kb_int_from_http_handler cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[BrokenPipeError(ESHUTDOWN)] cheroot/test/test_conn.py::test_readall_or_close[1001] cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[real socket.error(ENOTCONN)] [gw8] [ 21%] XFAIL cheroot/test/test_conn.py::test_Chunked_Encoding cheroot/test/test_conn.py::test_Content_Length_in [gw8] [ 21%] PASSED cheroot/test/test_conn.py::test_Content_Length_in [gw0] [ 22%] PASSED cheroot/test/test_core.py::test_query_string_request [gw7] [ 22%] PASSED cheroot/test/test_conn.py::test_keepalive[HTTP/1.0] cheroot/test/test_core.py::test_parse_acceptable_uri[/query_string?test=True] [gw7] [ 23%] PASSED cheroot/test/test_core.py::test_parse_acceptable_uri[/query_string?test=True] [gw11] [ 23%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[BrokenPipeError(ESHUTDOWN)] cheroot/test/test_core.py::test_parse_acceptable_uri[/hello] [gw12] [ 24%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(-1)] cheroot/test/test_conn.py::test_Content_Length_not_int [gw5] [ 25%] PASSED cheroot/test/test_conn.py::test_streaming_11[True] cheroot/test/test_core.py::test_malformed_request_line[GET /-400-Malformed Request-Line] [gw4] [ 25%] PASSED cheroot/test/test_conn.py::test_HTTP11_Timeout[True] cheroot/test/test_conn.py::test_HTTP11_Timeout[False] [gw2] [ 26%] PASSED cheroot/test/test_conn.py::test_invalid_selected_connection cheroot/test/test_core.py::test_parse_uri_invalid_uri [gw11] [ 26%] PASSED cheroot/test/test_core.py::test_malformed_request_line[GET /-400-Malformed Request-Line] cheroot/test/test_core.py::test_malformed_request_line[GET / HTTPS/1.1-400-Malformed Request-Line: bad protocol] [gw0] [ 27%] PASSED cheroot/test/test_core.py::test_parse_acceptable_uri[/hello] [gw3] [ 27%] PASSED cheroot/test/test_conn.py::test_readall_or_close[1001] cheroot/test/test_core.py::test_parse_uri_absolute_uri [gw12] [ 28%] PASSED cheroot/test/test_core.py::test_parse_uri_absolute_uri cheroot/test/test_core.py::test_parse_acceptable_uri[/%D0%AE%D1%85%D1%85%D1%83%D1%83%D1%83?%D1%97=%D0%B9%D0%BE] [gw7] [ 28%] PASSED cheroot/test/test_core.py::test_parse_acceptable_uri[/%D0%AE%D1%85%D1%85%D1%83%D1%83%D1%83?%D1%97=%D0%B9%D0%BE] cheroot/test/test_core.py::test_http_connect_request [gw1] [ 29%] PASSED cheroot/test/test_conn.py::test_kb_int_from_http_handler cheroot/test/test_conn.py::test_unhandled_exception_in_request_handler [gw6] [ 29%] XFAIL cheroot/test/test_conn.py::test_598 cheroot/test/test_core.py::test_parse_uri_asterisk_uri [gw8] [ 30%] PASSED cheroot/test/test_conn.py::test_Content_Length_not_int cheroot/test/test_core.py::test_parse_uri_unsafe_uri [gw11] [ 30%] PASSED cheroot/test/test_core.py::test_malformed_request_line[GET / HTTPS/1.1-400-Malformed Request-Line: bad protocol] [gw2] [ 31%] PASSED cheroot/test/test_core.py::test_http_connect_request [gw5] [ 32%] PASSED cheroot/test/test_core.py::test_parse_uri_invalid_uri cheroot/test/test_conn.py::test_No_Message_Body [gw1] [ 32%] PASSED cheroot/test/test_conn.py::test_unhandled_exception_in_request_handler cheroot/test/test_conn.py::test_remains_alive_post_unhandled_exception [gw9] [ 33%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[real socket.error(ENOTCONN)] cheroot/test/test_core.py::test_malformed_request_line[GET / HTTP/2.15-505-Cannot fulfill request] [gw3] [ 33%] PASSED cheroot/test/test_conn.py::test_No_Message_Body cheroot/test/test_conn.py::test_No_CRLF[\n\n] [gw0] [ 34%] PASSED cheroot/test/test_core.py::test_malformed_request_line[GET / HTTP/2.15-505-Cannot fulfill request] [gw10] [ 34%] PASSED cheroot/test/test_conn.py::test_keepalive_conn_management cheroot/test/test_conn.py::test_Content_Length_out[/wrong_cl_buffered-500-The requested resource returned more bytes than the declared Content-Length.] [gw6] [ 35%] PASSED cheroot/test/test_conn.py::test_No_CRLF[\n\n] cheroot/test/test_core.py::test_malformed_request_line[GET / HTTP/1-400-Malformed Request-Line: bad version] cheroot/test/test_core.py::test_request_line_split_issue_1220 [gw8] [ 35%] PASSED cheroot/test/test_conn.py::test_Content_Length_out[/wrong_cl_buffered-500-The requested resource returned more bytes than the declared Content-Length.] [gw11] [ 36%] PASSED cheroot/test/test_core.py::test_malformed_request_line[GET / HTTP/1-400-Malformed Request-Line: bad version] [gw2] [ 36%] PASSED cheroot/test/test_core.py::test_request_line_split_issue_1220 cheroot/test/test_core.py::test_no_content_length cheroot/test/test_core.py::test_parse_no_leading_slash_invalid[hello] [gw12] [ 37%] PASSED cheroot/test/test_core.py::test_parse_uri_asterisk_uri [gw7] [ 38%] PASSED cheroot/test/test_core.py::test_parse_uri_unsafe_uri [gw9] [ 38%] PASSED cheroot/test/test_core.py::test_no_content_length [gw5] [ 39%] PASSED cheroot/test/test_core.py::test_parse_no_leading_slash_invalid[hello] cheroot/test/test_errors.py::test_plat_specific_errors[err_names0-err_nums0] [gw3] [ 39%] PASSED cheroot/test/test_errors.py::test_plat_specific_errors[err_names0-err_nums0] cheroot/test/test_errors.py::test_plat_specific_errors[err_names1-err_nums1] [gw3] [ 40%] PASSED cheroot/test/test_errors.py::test_plat_specific_errors[err_names1-err_nums1] cheroot/test/test_server.py::test_serving_is_false_and_stop_returns_after_ctrlc cheroot/test/test_core.py::test_malformed_http_method cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(ECONNRESET)] [gw1] [ 40%] PASSED cheroot/test/test_conn.py::test_remains_alive_post_unhandled_exception cheroot/test/test_makefile.py::test_bytes_read [gw1] [ 41%] PASSED cheroot/test/test_makefile.py::test_bytes_read cheroot/test/test_makefile.py::test_bytes_written [gw1] [ 41%] PASSED cheroot/test/test_makefile.py::test_bytes_written cheroot/test/test_server.py::test_bind_addr_unix[file] [gw3] [ 42%] PASSED cheroot/test/test_server.py::test_serving_is_false_and_stop_returns_after_ctrlc cheroot/test/test_server.py::test_prepare_makes_server_ready cheroot/test/test_server.py::test_bind_addr_inet[0.0.0.0] [gw0] [ 42%] PASSED cheroot/test/test_core.py::test_malformed_http_method cheroot/test/test_server.py::test_server_interrupt[OSError0] [gw10] [ 43%] PASSED cheroot/test/test_conn.py::test_broken_connection_during_tcp_fin[socket.error(ECONNRESET)] cheroot/test/test_server.py::test_server_interrupt[OSError1] cheroot/test/test_core.py::test_garbage_in [gw6] [ 44%] PASSED cheroot/test/test_server.py::test_prepare_makes_server_ready cheroot/test/test_server.py::test_stop_interrupts_serve cheroot/test/test_core.py::test_parse_uri_fragment_uri [gw3] [ 44%] PASSED cheroot/test/test_server.py::test_bind_addr_inet[0.0.0.0] cheroot/test/test_core.py::test_content_length_required [gw2] [ 45%] PASSED cheroot/test/test_core.py::test_garbage_in cheroot/test/test_core.py::test_send_header_before_closing [gw1] [ 45%] PASSED cheroot/test/test_server.py::test_bind_addr_unix[file] [gw12] [ 46%] PASSED cheroot/test/test_core.py::test_parse_uri_fragment_uri cheroot/test/test_core.py::test_parse_no_leading_slash_invalid[\u043f\u0440\u0438\u0432\u0456\u0442] [gw7] [ 46%] PASSED cheroot/test/test_core.py::test_send_header_before_closing [gw5] [ 47%] PASSED cheroot/test/test_core.py::test_parse_no_leading_slash_invalid[\u043f\u0440\u0438\u0432\u0456\u0442] [gw9] [ 47%] PASSED cheroot/test/test_core.py::test_content_length_required cheroot/test/test_server.py::test_bind_addr_inet[::] cheroot/test/test_core.py::test_malformed_header cheroot/test/test_core.py::test_large_request [gw10] [ 48%] PASSED cheroot/test/test_server.py::test_bind_addr_inet[::] [gw0] [ 48%] PASSED cheroot/test/test_core.py::test_malformed_header [gw6] [ 49%] PASSED cheroot/test/test_server.py::test_stop_interrupts_serve cheroot/test/test_server.py::test_high_number_of_file_descriptors[1024] cheroot/test/test_server.py::test_bind_addr_unix_abstract cheroot/test/test_server.py::test_peercreds_unix_sock_with_lookup[abstract] cheroot/test/test_server.py::test_peercreds_unix_sock[abstract] [gw8] [ 50%] PASSED cheroot/test/test_server.py::test_server_interrupt[OSError0] cheroot/test/test_server.py::test_server_interrupt[KeyboardInterrupt] cheroot/test/test_server.py::test_reuse_port[0.0.0.0] [gw4] [ 50%] PASSED cheroot/test/test_conn.py::test_HTTP11_Timeout[False] cheroot/test/test_conn.py::test_HTTP11_Timeout_after_request [gw1] [ 51%] PASSED cheroot/test/test_server.py::test_bind_addr_unix_abstract [gw12] [ 51%] PASSED cheroot/test/test_server.py::test_reuse_port[0.0.0.0] cheroot/test/test_dispatch.py::test_dispatch_no_script_name cheroot/test/test_server.py::test_threadpool_threadrange_set[1-inf-inf] [gw12] [ 52%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[1-inf-inf] [gw7] [ 52%] PASSED cheroot/test/test_dispatch.py::test_dispatch_no_script_name cheroot/test/test_server.py::test_threadpool_threadrange_set[2--2-inf] [gw12] [ 53%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[2--2-inf] cheroot/test/test_server.py::test_threadpool_threadrange_set[2--1-inf] [gw7] [ 53%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[2--1-inf] cheroot/test/test_server.py::test_threadpool_threadrange_set[2-2-2] [gw12] [ 54%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[2-2-2] cheroot/test/test_server.py::test_reuse_port[::] cheroot/test/test_server.py::test_threadpool_threadrange_set[2-inf-inf] [gw7] [ 54%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[2-inf-inf] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1--1-min=-1 must be > 0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-0-min=-1 must be > 0] [gw12] [ 55%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1--1-min=-1 must be > 0] [gw7] [ 55%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-0-min=-1 must be > 0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-2-min=-1 must be > 0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0--1-min=0 must be > 0] [gw12] [ 56%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-2-min=-1 must be > 0] [gw7] [ 57%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0--1-min=0 must be > 0] [gw5] [ 57%] PASSED cheroot/test/test_server.py::test_reuse_port[::] [gw2] [ 58%] PASSED cheroot/test/test_server.py::test_peercreds_unix_sock_with_lookup[abstract] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-0-min=0 must be > 0] [gw12] [ 58%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-0-min=0 must be > 0] [gw3] [ 59%] PASSED cheroot/test/test_server.py::test_peercreds_unix_sock[abstract] [gw6] [ 59%] PASSED cheroot/test/test_server.py::test_high_number_of_file_descriptors[1024] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-1-min=-1 must be > 0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-2-min=0 must be > 0] cheroot/test/test_server.py::test_bind_addr_unix[abstract] [gw5] [ 60%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[-1-1-min=-1 must be > 0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-1-min=0 must be > 0] [gw7] [ 60%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-1-min=0 must be > 0] cheroot/test/test_server.py::test_peercreds_unix_sock_with_lookup[file] [gw12] [ 61%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[0-2-min=0 must be > 0] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-0-Expected an integer or the infinity value for the `max` argument but got 0.] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[1-0-Expected an integer or the infinity value for the `max` argument but got 0.] [gw11] [ 61%] PASSED cheroot/test/test_server.py::test_server_interrupt[OSError1] cheroot/test/test_server.py::test_peercreds_unix_sock[file] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-1-Expected an integer or the infinity value for the `max` argument but got '1'.] [gw5] [ 62%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-0-Expected an integer or the infinity value for the `max` argument but got 0.] [gw7] [ 63%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[1-0-Expected an integer or the infinity value for the `max` argument but got 0.] cheroot/test/test_server.py::test_threadpool_threadrange_set[1--2-inf] [gw0] [ 63%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[1--2-inf] [gw12] [ 64%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-1-Expected an integer or the infinity value for the `max` argument but got '1'.] cheroot/test/test_server.py::test_server_interrupt[RuntimeError] cheroot/test/test_ssl.py::test_ssl_adapters[builtin] [gw10] [ 64%] PASSED cheroot/test/test_server.py::test_bind_addr_unix[abstract] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-localhost-builtin] cheroot/test/test_ssl.py::test_ssl_adapters[pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-localhost-pyopenssl] cheroot/test/test_server.py::test_threadpool_threadrange_set[1-1-1] [gw1] [ 65%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[1-1-1] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-not_localhost-pyopenssl] [gw9] [ 65%] XFAIL cheroot/test/test_core.py::test_large_request [gw2] [ 66%] PASSED cheroot/test/test_server.py::test_peercreds_unix_sock_with_lookup[file] cheroot/test/test_server.py::test_threadpool_multistart_validation [gw2] [ 66%] PASSED cheroot/test/test_server.py::test_threadpool_multistart_validation cheroot/test/test_ssl.py::test_tls_client_auth[0-False-localhost-pyopenssl] cheroot/test/test_server.py::test_high_number_of_file_descriptors[2048] cheroot/test/test_server.py::test_threadpool_threadrange_set[1--1-inf] [gw9] [ 67%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[1--1-inf] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-127.0.0.1-builtin] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[1-0.5-Expected an integer or the infinity value for the `max` argument but got 0.5.] [gw12] [ 67%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-localhost-pyopenssl] [gw7] [ 68%] PASSED cheroot/test/test_ssl.py::test_ssl_adapters[pyopenssl] [gw10] [ 69%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[1-0.5-Expected an integer or the infinity value for the `max` argument but got 0.5.] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-*.localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-not_localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-*.localhost-builtin] [gw3] [ 69%] PASSED cheroot/test/test_server.py::test_peercreds_unix_sock[file] cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-1-max=1 must be > min=2] [gw3] [ 70%] PASSED cheroot/test/test_server.py::test_threadpool_invalid_threadrange[2-1-max=1 must be > min=2] [gw11] [ 70%] PASSED cheroot/test/test_server.py::test_server_interrupt[RuntimeError] [gw6] [ 71%] PASSED cheroot/test/test_server.py::test_high_number_of_file_descriptors[2048] cheroot/test/test_ssl.py::test_tls_client_auth[1-False-localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-127.0.0.1-builtin] [gw8] [ 71%] PASSED cheroot/test/test_server.py::test_server_interrupt[KeyboardInterrupt] cheroot/test/test_server.py::test_threadpool_threadrange_set[1-2-2] [gw8] [ 72%] PASSED cheroot/test/test_server.py::test_threadpool_threadrange_set[1-2-2] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-localhost-pyopenssl] [gw12] [ 72%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-not_localhost-builtin] [gw5] [ 73%] PASSED cheroot/test/test_ssl.py::test_ssl_adapters[builtin] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-not_localhost-builtin] [gw2] [ 73%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-False-localhost-pyopenssl] [gw7] [ 74%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-*.localhost-builtin] [gw8] [ 75%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-localhost-pyopenssl] [gw10] [ 75%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-*.localhost-builtin] [gw12] [ 76%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-not_localhost-builtin] [gw9] [ 76%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-127.0.0.1-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-127.0.0.1-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-127.0.0.1-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-*.localhost-pyopenssl] [gw11] [ 77%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-127.0.0.1-builtin] [gw1] [ 77%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-not_localhost-pyopenssl] [gw0] [ 78%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-localhost-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[0-False-localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-*.localhost-pyopenssl] [gw12] [ 78%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-127.0.0.1-pyopenssl] [gw3] [ 79%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-False-localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[0-True-127.0.0.1-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-*.localhost-pyopenssl] [gw10] [ 79%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-*.localhost-pyopenssl] [gw8] [ 80%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-127.0.0.1-builtin] [gw0] [ 80%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-*.localhost-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-not_localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[2-False-localhost-pyopenssl] [gw12] [ 81%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-*.localhost-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-not_localhost-pyopenssl] [gw6] [ 82%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-localhost-pyopenssl] [gw5] [ 82%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-True-127.0.0.1-pyopenssl] [gw1] [ 83%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[0-False-localhost-builtin] cheroot/test/test_ssl.py::test_ssl_env[0-False-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[1-True-127.0.0.1-pyopenssl] [gw7] [ 83%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-not_localhost-pyopenssl] [gw0] [ 84%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-False-localhost-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[1-False-pyopenssl] [gw10] [ 84%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-not_localhost-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-localhost-builtin] [gw9] [ 85%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-127.0.0.1-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[1-False-localhost-pyopenssl] [gw7] [ 85%] PASSED cheroot/test/test_ssl.py::test_ssl_env[1-False-pyopenssl] [gw5] [ 86%] PASSED cheroot/test/test_ssl.py::test_ssl_env[0-False-builtin] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-*.localhost-builtin] [gw11] [ 86%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-localhost-builtin] cheroot/test/test_ssl.py::test_ssl_env[2-True-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[0-False-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[2-True-not_localhost-pyopenssl] cheroot/test/test_ssl.py::test_tls_client_auth[2-False-localhost-builtin] [gw3] [ 87%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-False-localhost-pyopenssl] [gw2] [ 88%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[1-True-localhost-builtin] cheroot/test/test_ssl.py::test_ssl_env[1-False-builtin] cheroot/test/test_ssl.py::test_ssl_env[0-True-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[0-True-builtin] [gw12] [ 88%] PASSED cheroot/test/test_ssl.py::test_ssl_env[0-False-pyopenssl] [gw8] [ 89%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-*.localhost-builtin] [gw11] [ 89%] PASSED cheroot/test/test_ssl.py::test_ssl_env[2-True-pyopenssl] cheroot/test/test_ssl.py::test_http_over_https_error[::-pyopenssl] cheroot/test/test_ssl.py::test_ssl_env[1-True-pyopenssl] [gw6] [ 90%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-True-not_localhost-pyopenssl] cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-pyopenssl] cheroot/test/test_ssl.py::test_http_over_https_error[::-builtin] cheroot/test/test_wsgi.py::test_connection_keepalive cheroot/test/test_ssl.py::test_ssl_env[2-True-builtin] cheroot/test/test_ssl.py::test_ssl_env[1-True-builtin] [gw1] [ 90%] PASSED cheroot/test/test_ssl.py::test_tls_client_auth[2-False-localhost-builtin] [gw2] [ 91%] PASSED cheroot/test/test_ssl.py::test_ssl_env[0-True-pyopenssl] [gw9] [ 91%] PASSED cheroot/test/test_ssl.py::test_ssl_env[1-True-pyopenssl] cheroot/test/webtest.py::cheroot.test.webtest.WebCase.getPage [gw0] [ 92%] PASSED cheroot/test/test_ssl.py::test_ssl_env[1-False-builtin] cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-builtin] cheroot/test/test_wsgi.py::test_gateway_write_needs_start_response_called_before [gw0] [ 92%] PASSED cheroot/test/test_wsgi.py::test_gateway_write_needs_start_response_called_before [gw10] [ 93%] PASSED cheroot/test/test_ssl.py::test_ssl_env[0-True-builtin] [gw7] [ 94%] PASSED cheroot/test/test_ssl.py::test_ssl_env[2-True-builtin] [gw2] [ 94%] PASSED cheroot/test/webtest.py::cheroot.test.webtest.WebCase.getPage [gw5] [ 95%] PASSED cheroot/test/test_ssl.py::test_ssl_env[1-True-builtin] [gw8] [ 95%] PASSED cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-pyopenssl] cheroot/test/test_wsgi.py::test_gateway_start_response_called_twice [gw1] [ 96%] PASSED cheroot/test/test_wsgi.py::test_gateway_start_response_called_twice [gw12] [ 96%] PASSED cheroot/test/test_ssl.py::test_http_over_https_error[::-pyopenssl] [gw11] [ 97%] PASSED cheroot/test/test_ssl.py::test_http_over_https_error[::-builtin] cheroot/test/webtest.py::cheroot.test.webtest.strip_netloc [gw10] [ 97%] PASSED cheroot/test/webtest.py::cheroot.test.webtest.strip_netloc [gw3] [ 98%] PASSED cheroot/test/test_ssl.py::test_http_over_https_error[0.0.0.0-builtin] [gw4] [ 98%] PASSED cheroot/test/test_conn.py::test_HTTP11_Timeout_after_request cheroot/test/test_conn.py::test_HTTP11_pipelining [gw4] [ 99%] PASSED cheroot/test/test_conn.py::test_HTTP11_pipelining [gw6] [100%] PASSED cheroot/test/test_wsgi.py::test_connection_keepalive - generated xml file: /build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.12_cheroot/build/.test-results/pytest/test.xml - ---------- coverage: platform linux, python 3.12.8-final-0 ----------- Name Stmts Miss Cover Missing -------------------------------------------------------------- cheroot/__init__.py 10 10 0% 3-14 cheroot/__main__.py 3 3 0% 3-6 cheroot/_compat.py 35 2 94% 12-13 cheroot/cli.py 70 22 69% 86, 93, 101-107, 111, 119, 123-129, 150-151, 232-243 cheroot/connections.py 178 31 83% 17-39, 227, 284, 325, 339-344, 351-375 cheroot/errors.py 20 2 90% 55-56 cheroot/makefile.py 41 2 95% 20, 35 cheroot/server.py 1032 241 77% 120-127, 132-135, 139-144, 198, 204, 218, 229, 234, 251-252, 270, 281-284, 296-299, 323-332, 336, 340, 344-347, 374, 393-402, 414-423, 427, 431, 435-437, 465, 471, 480-481, 493, 501, 518, 522, 531-533, 547-578, 590-599, 608-629, 633, 716-721, 728-734, 768-770, 838-864, 907-911, 928-930, 937, 960-961, 1028-1030, 1059-1061, 1072-1078, 1110, 1150, 1283, 1328, 1355, 1357, 1393, 1397, 1408-1416, 1448, 1667-1670, 1674, 1721, 1735, 1740, 1759, 1764-1766, 1777-1785, 1792-1796, 1799, 1821-1822, 1903-1907, 1917, 1921-1927, 1937, 1951-1952, 1956-1958, 1965-1971, 1974, 1989, 1992, 1999, 2002-2005, 2055-2058, 2094-2096, 2146-2151, 2171-2173, 2217, 2225-2226 cheroot/ssl/builtin.py 191 29 85% 17-18, 22-26, 37, 73, 101-102, 127, 206, 218, 225, 233, 236, 273, 289-290, 318, 365, 396, 406-407, 421, 430, 441-442 cheroot/ssl/pyopenssl.py 144 20 86% 65-68, 100, 105-108, 111, 116-117, 126, 130, 150, 158, 272, 283, 304, 378 cheroot/test/_pytest_plugin.py 6 4 33% 7-13, 16 cheroot/test/conftest.py 54 4 93% 29, 32, 55-56 cheroot/test/helper.py 99 42 58% 42-70, 75-76, 81-83, 88-91, 97-105, 135, 150-151, 166 cheroot/test/test_conn.py 719 33 95% 55, 97, 175-178, 306-311, 1049-1053, 1077-1080, 1083, 1177, 1351-1364, 1477-1479 cheroot/test/test_core.py 220 7 97% 32, 296-298, 403-406, 439 cheroot/test/test_makefile.py 30 4 87% 24-27 cheroot/test/test_server.py 242 5 98% 54, 238, 265, 307, 408 cheroot/test/test_ssl.py 251 30 88% 89, 153-156, 338, 354, 358, 364-368, 378, 430, 551, 553-569, 574, 590-603, 637, 687, 691 cheroot/test/webtest.py 306 176 42% 54-57, 62-64, 72-79, 94-96, 125-126, 130-134, 145-150, 159, 163, 171, 198-228, 238-246, 251-296, 301, 305-310, 318-323, 327-338, 342-351, 355-362, 366-371, 375-381, 385-392, 396-401, 405-410, 414-419, 439, 451-454, 478, 502-505, 509, 518, 524, 579-588 cheroot/testing.py 88 9 90% 46-47, 147-149, 153, 165-167 cheroot/workers/threadpool.py 176 38 78% 26, 29, 163, 218-222, 305-310, 320, 336-352, 363-364, 394-395, 400-411, 426 cheroot/wsgi.py 144 33 77% 88, 92, 140, 163-164, 170, 174, 194, 271-282, 325-342, 396-402 -------------------------------------------------------------- TOTAL 4193 747 82% 8 files skipped due to complete coverage. Coverage XML written to file .test-results/pytest/cov.xml ============================= slowest 10 durations ============================= 18.10s call cheroot/test/test_wsgi.py::test_connection_keepalive 4.05s call cheroot/test/test_conn.py::test_HTTP11_Timeout_after_request 3.44s call cheroot/test/test_conn.py::test_keepalive_conn_management 2.01s call cheroot/test/test_conn.py::test_HTTP11_Timeout[False] 2.00s call cheroot/test/test_conn.py::test_HTTP11_Timeout[True] 1.24s call cheroot/test/test_server.py::test_server_interrupt[KeyboardInterrupt] 1.16s call cheroot/test/test_server.py::test_server_interrupt[OSError1] 1.05s call cheroot/test/test_conn.py::test_invalid_selected_connection 0.95s setup cheroot/test/test_conn.py::test_keepalive[HTTP/1.0] 0.93s call cheroot/test/test_conn.py::test_broken_connection_during_http_communication_fallback =========================== short test summary info ============================ XFAIL cheroot/test/test_conn.py::test_Chunked_Encoding - Headers from earlier request leak into the request line for a subsequent request, resulting in 400 instead of 413. See cherrypy/cheroot#69 for details. XFAIL cheroot/test/test_conn.py::test_598 - Sometimes this test fails due to low timeout. Ref: https://github.com/cherrypy/cherrypy/issues/598 XFAIL cheroot/test/test_core.py::test_large_request - https://github.com/cherrypy/cheroot/issues/106 ================== 181 passed, 3 xfailed in 106.85s (0:01:46) ================== I: pybuild pybuild:334: rm -Rf /build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.12_cheroot/build/.test-results /build/reproducible-path/python-cheroot-10.0.1+ds1/.pybuild/cpython3_3.12_cheroot/build/.coverage dh_auto_test: error: pybuild --test --test-pytest -i python{version} -p "3.13 3.12" returned exit code 13 make: *** [debian/rules:13: binary] Error 25 dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2 I: copying local configuration E: Failed autobuilding of package I: user script /srv/workspace/pbuilder/36977/tmp/hooks/C01_cleanup starting debug output: disk usage on i-capture-the-hostname at Thu Dec 12 06:50:31 UTC 2024 Filesystem Size Used Avail Use% Mounted on tmpfs 3.9G 0 3.9G 0% /dev/shm I: user script /srv/workspace/pbuilder/36977/tmp/hooks/C01_cleanup finished 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/36977 and its subdirectories