Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 932660 - net-misc/curl-8.8.0 fails 1553 test with FEATURES="network-sandbox"
Summary: net-misc/curl-8.8.0 fails 1553 test with FEATURES="network-sandbox"
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Matt Jolly
URL:
Whiteboard:
Keywords: TESTFAILURE
Depends on:
Blocks:
 
Reported: 2024-05-24 20:26 UTC by Toralf Förster
Modified: 2024-05-30 02:02 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge-info.txt (emerge-info.txt,19.30 KB, text/plain)
2024-05-24 20:27 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,59.64 KB, text/plain)
2024-05-24 20:27 UTC, Toralf Förster
Details
environment (environment,114.78 KB, text/plain)
2024-05-24 20:27 UTC, Toralf Förster
Details
etc.clang.tar.xz (etc.clang.tar.xz,1.21 KB, application/x-xz)
2024-05-24 20:27 UTC, Toralf Förster
Details
etc.portage.tar.xz (etc.portage.tar.xz,34.84 KB, application/x-xz)
2024-05-24 20:27 UTC, Toralf Förster
Details
logs.tar.xz (logs.tar.xz,30.84 KB, application/x-xz)
2024-05-24 20:27 UTC, Toralf Förster
Details
net-misc:curl-8.8.0:20240524-191722.log.xz (net-misc:curl-8.8.0:20240524-191722.log.xz,95.25 KB, application/x-xz)
2024-05-24 20:27 UTC, Toralf Förster
Details
qlist-info.txt (qlist-info.txt,122.18 KB, text/plain)
2024-05-24 20:27 UTC, Toralf Förster
Details
temp.tar.xz (temp.tar.xz,120.51 KB, application/x-xz)
2024-05-24 20:27 UTC, Toralf Förster
Details
tests.tar.xz (tests.tar.xz,386.15 KB, application/x-xz)
2024-05-24 20:27 UTC, Toralf Förster
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2024-05-24 20:26:58 UTC
Runner 18522 exiting
Runner 18520 exiting
Runner 18515 exiting
make[1]: *** [Makefile:874: quiet-test] Error 1
make[1]: Leaving directory '/var/tmp/portage/net-misc/curl-8.8.0/work/curl-8.8.0-abi_x86_64.amd64/tests'
make: *** [Makefile:1678: test] Error 2
 * ERROR: net-misc/curl-8.8.0::gentoo failed (test phase):
 *   emake failed

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 23.0_desktop_systemd_test-20240518-162232

  The attached etc.portage.tar.xz has all details.
  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-14 *
clang/llvm (if any):
clang version 18.1.5
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/18/bin
Configuration file: /etc/clang/x86_64-pc-linux-gnu-clang.cfg
/usr/lib/llvm/18
18.1.6
Python 3.11.9
Available Ruby profiles:
  [1]   ruby31 (with Rubygems)
  [2]   ruby32 (with Rubygems)
  [3]   ruby33 (with Rubygems) *
Available Rust versions:
  [1]   rust-bin-1.77.1 *
php cli (if any):
go version go1.22.3 linux/amd64

  HEAD of ::gentoo
commit 7ec4d51c1b449743ff606a27d27e3e623d092c3d
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Fri May 24 15:48:49 2024 +0000

    2024-05-24 15:48:48 UTC

emerge -qpvO net-misc/curl
[ebuild     U ] net-misc/curl-8.8.0 [8.7.1-r4] USE="adns alt-svc ftp gnutls* hsts http2* imap mbedtls* openssl pop3 psl rtmp* rustls* samba* smtp ssh* ssl test* tftp websockets* -brotli -gopher -idn -kerberos -ldap -nghttp3 -progress-meter* (-sslv3) -static-libs -telnet -verify-sig -zstd" ABI_X86="(64) -32 (-x32)" CURL_SSL="openssl -gnutls -mbedtls -rustls"
Comment 1 Toralf Förster gentoo-dev 2024-05-24 20:27:00 UTC
Created attachment 894287 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2024-05-24 20:27:01 UTC
Created attachment 894288 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2024-05-24 20:27:03 UTC
Created attachment 894289 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2024-05-24 20:27:03 UTC
Created attachment 894290 [details]
etc.clang.tar.xz
Comment 5 Toralf Förster gentoo-dev 2024-05-24 20:27:04 UTC
Created attachment 894291 [details]
etc.portage.tar.xz
Comment 6 Toralf Förster gentoo-dev 2024-05-24 20:27:06 UTC
Created attachment 894292 [details]
logs.tar.xz
Comment 7 Toralf Förster gentoo-dev 2024-05-24 20:27:07 UTC
Created attachment 894293 [details]
net-misc:curl-8.8.0:20240524-191722.log.xz
Comment 8 Toralf Förster gentoo-dev 2024-05-24 20:27:08 UTC
Created attachment 894294 [details]
qlist-info.txt
Comment 9 Toralf Förster gentoo-dev 2024-05-24 20:27:10 UTC
Created attachment 894295 [details]
temp.tar.xz
Comment 10 Toralf Förster gentoo-dev 2024-05-24 20:27:11 UTC
Created attachment 894296 [details]
tests.tar.xz
Comment 11 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-05-25 02:08:35 UTC
I'm seeing this too.
Comment 12 Matt Jolly gentoo-dev 2024-05-25 21:48:29 UTC
I saw this when doing mbedtls patching on one machine, but _not_ on the machine where I first packaged this.

Daniel and Jay over at cURL, and their CI aren't seeing it either.

iirc this is an IMAP test. What are _we_ doing that's different here?
Comment 13 Matt Jolly gentoo-dev 2024-05-26 00:09:46 UTC
I'm not quite sure what's happening here. The test seems to be hanging. If I run it with -network-sandbox it consistently passes (can anyone validate?), but I also have one machine where it just works all the time.

I've raised the issue upstream.
Comment 14 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-05-27 23:01:21 UTC
Just to dump how I bisected in case someone finds it useful:
"""
[23:03] <sam_> for bisecting, I'm doing https://wiki.gentoo.org/wiki/Bisecting_with_live_ebuilds
[23:03] <sam_> i.e.
[23:03] <sam_> cloned curl
[23:03] <sam_>  
[23:03] <sam_> /tmp/bisect.sh
[23:03] <sam_> #!/bin/bash
[23:03] <sam_> export EGIT_OVERRIDE_COMMIT_CURL_CURL=$(git rev-parse HEAD)
[23:03] <sam_> export EGIT_OVERRIDE_BRANCH_CURL_CURL=master
[23:03] <sam_> export ACCEPT_KEYWORDS="**"
[23:03] <sam_> FEATURES="network-sandbox" CFLAGS="-O2" LDFLAGS="-Wl,-O1" CC=gcc-13 e /home/sam/git/gentoo/net-misc/curl/curl-9999.ebuild clean compile || exit 125
[23:03] <sam_> FEATURES="network-sandbox" CFLAGS="-O2" LDFLAGS="-Wl,-O1" CC=gcc-13 e /home/sam/git/gentoo/net-misc/curl/curl-9999.ebuild test
[23:03] <sam_> if grep -q 'TESTFAIL: These test cases failed: 1553' /var/tmp/portage/net-misc/curl-9999/temp/build.log ; then
[23:03] <sam_>         exit 1
[23:03] <sam_> fi
[23:03] <sam_> exit 0
[23:03] <sam_>  
[23:03] <sam_> git bisect bad master
[23:03] <sam_> git bisect bad curl-8_8_0
[23:03] <sam_> git bisect good curl-8_7_1
[23:04] <sam_> chmod +x /tmp/bisect.sh
[23:04] <sam_> git bisect run /tmp/bisect.sh
[23:04] <sam_> with the ebuild modified as:
[23:04] <sam_> -       multilib_is_native_abi && emake test TFLAGS="-n -v -a -k -am -p -j$((2*$(makeopts_jobs))) !241 !1083"
[23:04] <sam_> +       multilib_is_native_abi && emake test TFLAGS="-n -v -a -k -am -p -j1 !241 !1083 1553"
[23:04] <sam_> (to run only 1553)
[23:05] <sam_>
"""

which then gave:
"""
[23:08] <sam_> 2d2c27e5a319665fdfbe75422dac55ff3a2218b6 is the first bad commit
[23:08] <sam_> commit 2d2c27e5a319665fdfbe75422dac55ff3a2218b6
[23:08] <sam_> Author: Stefan Eissing <stefan@eissing.org>
[23:08] <sam_> Date:   Wed Mar 20 08:08:43 2024 +0100
[23:08] <sam_>     multi: multi_wait improvements
"""

It indeed passes for me with FEATURES="-network-sandbox" or running the test manually outside of the ebuild. It consistently fails for me with network-sandbox on.
Comment 15 Larry the Git Cow gentoo-dev 2024-05-30 02:02:18 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b4a094f4165eba939dc23b9af9c660ab3b45f449

commit b4a094f4165eba939dc23b9af9c660ab3b45f449
Author:     Matt Jolly <kangie@gentoo.org>
AuthorDate: 2024-05-30 00:30:56 +0000
Commit:     Matt Jolly <kangie@gentoo.org>
CommitDate: 2024-05-30 02:02:10 +0000

    net-misc/curl: add 8.8.0-r1
    
    This release fixes an issue where under certain circumstances
    (in particular when invoked within the Gentoo sandbox), `multi_wait()`
    would incorrectly calculate the timeout, resulting in test failures.
    
    Allow setting `--enable-debug` via USE=debug with an appropriate warning
    to the ebuild and live ebuild.
    
    Closes: https://bugs.gentoo.org/932660
    See-also: https://github.com/curl/curl/issues/13782
    Signed-off-by: Matt Jolly <kangie@gentoo.org>

 net-misc/curl/curl-8.8.0-r1.ebuild                 | 387 +++++++++++++++++++++
 net-misc/curl/curl-9999.ebuild                     |  16 +-
 .../curl/files/curl-8.8.0-multi_wait-timeout.patch |  75 ++++
 3 files changed, 477 insertions(+), 1 deletion(-)