Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 791748 - dev-python/eventlet-0.30.2-r1: fails tests.patcher_test.test_fork_after_monkey_patch test
Summary: dev-python/eventlet-0.30.2-r1: fails tests.patcher_test.test_fork_after_monke...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Python Gentoo Team
URL:
Whiteboard:
Keywords: TESTFAILURE
Depends on:
Blocks: 790881
  Show dependency tree
 
Reported: 2021-05-24 02:39 UTC by Sam James
Modified: 2021-11-29 17:15 UTC (History)
2 users (show)

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


Attachments
build.log (file_791748.txt,151.62 KB, text/plain)
2021-05-24 02:39 UTC, Sam James
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-05-24 02:39:24 UTC
Created attachment 710847 [details]
build.log

tests.patcher_test.test_fork_after_monkey_patch ...  * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
 * Unable to trace static ELF: /sbin/ldconfig: /sbin/ldconfig -p 
Program /var/tmp/portage/dev-python/eventlet-0.30.2-r1/work/eventlet-0.30.2/tests/isolated/patcher_fork_after_monkey_patch.py output:
---
Traceback (most recent call last):
  File "/var/tmp/portage/dev-python/eventlet-0.30.2-r1/work/eventlet-0.30.2/tests/isolated/patcher_fork_after_monkey_patch.py", line 49, in <module>
    check(2, threading, 'post-fork patched')
  File "/var/tmp/portage/dev-python/eventlet-0.30.2-r1/work/eventlet-0.30.2/tests/isolated/patcher_fork_after_monkey_patch.py", line 7, in check
    assert len(mod._active) == n, 'Expected {} {} threads, got {}'.format(n, tag, mod._active)
AssertionError: Expected 2 post-fork patched threads, got {281473724506128: <_MainThread(MainThread, started 281473724506128)>}

---
FAIL

======================================================================
FAIL: tests.patcher_test.test_fork_after_monkey_patch
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3.8/site-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/var/tmp/portage/dev-python/eventlet-0.30.2-r1/work/eventlet-0.30.2/tests/patcher_test.py", line 521, in test_fork_after_monkey_patch
    tests.run_isolated('patcher_fork_after_monkey_patch.py')
  File "/var/tmp/portage/dev-python/eventlet-0.30.2-r1/work/eventlet-0.30.2/tests/__init__.py", line 381, in run_isolated
    run_python(prefix + path, **kwargs)
  File "/var/tmp/portage/dev-python/eventlet-0.30.2-r1/work/eventlet-0.30.2/tests/__init__.py", line 374, in run_python
    assert ok, 'Expected single line "pass" in stdout'
AssertionError: Expected single line "pass" in stdout

----------------------------------------------------------------------
Ran 424 tests in 260.621s

FAILED (SKIP=94, failures=1)
 * ERROR: dev-python/eventlet-0.30.2-r1::gentoo failed (test phase):
 *   (no error message)

----
Portage 3.0.18 (python 3.9.4-final-0, default/linux/arm64/17.0/desktop, gcc-10.2.0, glibc-2.33, 5.4.117-gentoo-dist aarch64)
=================================================================
System uname: Linux-5.4.117-gentoo-dist-aarch64-with-glibc2.33
KiB Mem:   131636508 total,  27241364 free
KiB Swap:   16777212 total,  16777212 free
Timestamp of repository gentoo: Mon, 24 May 2021 02:20:16 +0000
sh dash 0.5.11.3-r1
ld GNU ld (Gentoo 2.35.2 p1) 2.35.2
app-shells/bash:          5.1_p8::gentoo
dev-java/java-config:     2.3.1::gentoo
dev-lang/perl:            5.32.1::gentoo
dev-lang/python:          2.7.18_p9::gentoo, 3.8.9_p2::gentoo, 3.9.4_p1::gentoo
dev-lang/rust-bin:        1.51.0::gentoo
dev-util/cmake:           3.18.5::gentoo
sys-apps/baselayout:      2.7::gentoo
sys-apps/openrc:          0.42.1-r1::gentoo
sys-apps/sandbox:         2.23::gentoo
sys-devel/autoconf:       2.13-r1::gentoo, 2.69-r5::gentoo
sys-devel/automake:       1.16.3-r1::gentoo
sys-devel/binutils:       2.35.2::gentoo
sys-devel/gcc:            10.2.0-r5::gentoo, 11.1.0::gentoo
sys-devel/gcc-config:     2.4::gentoo
sys-devel/libtool:        2.4.6-r6::gentoo
sys-devel/make:           4.3::gentoo
sys-kernel/linux-headers: 5.10::gentoo (virtual/os-headers)
sys-libs/glibc:           2.33::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000
    sync-rsync-verify-max-age: 24
    sync-rsync-verify-metamanifest: yes
    sync-rsync-verify-jobs: 1
    sync-rsync-extra-opts:

ACCEPT_KEYWORDS="arm64"
ACCEPT_LICENSE="@FREE"
CBUILD="aarch64-unknown-linux-gnu"
CFLAGS="-O2 -pipe -march=native -frecord-gcc-switches"
CHOST="aarch64-unknown-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -pipe -march=native -frecord-gcc-switches"
DISTDIR="/var/cache/distfiles"
EMERGE_DEFAULT_OPTS="--keep-going --complete-graph --usepkg=y --with-bdeps=y --deep"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR"
FCFLAGS="-O2 -pipe -march=native -frecord-gcc-switches"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance buildpkg cgroup config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox mount-sandbox multilib-strict network-sandbox news parallel-fetch parallel-install pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe -march=native -frecord-gcc-switches"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="C.UTF8"
LDFLAGS="-O2 -pipe -march=native -frecord-gcc-switches -Wl,-O1 -Wl,--as-needed -Wl,--defsym=__gentoo_check_ldflags__=0"
MAKEOPTS="-j2"
PKGDIR="/var/cache/binpkgs"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
USE="X a52 aac acl acpi alsa arm64 berkdb bluetooth branding bzip2 cairo cdda cdr cli crypt cups dbus dri dts dvdr elogind emboss encode exif flac fortran gdbm gif gpm gtk gui hardened iconv icu ipv6 jpeg lcms libglvnd libnotify libtirpc mad mng mp3 mp4 mpeg ncurses nls nptl ogg opengl openmp pam pango pcre pdf png policykit ppds qt5 readline sdl seccomp spell split-usr ssl startup-notification svg tcpd tiff truetype udev udisks unicode upower usb vorbis wxwidgets x264 xattr xcb xml xv xvid zlib" ADA_TARGET="gnat_2018" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_ARM="edsp thumb thumb2 v4 v5 v6 v7 v8 vfp vfp-d32 vfpv3 vfpv4" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput" KERNEL="linux" L10N="en en-US en-GB" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-3 php7-4" POSTGRES_TARGETS="postgres10 postgres11" PYTHON_SINGLE_TARGET="python3_8" PYTHON_TARGETS="python3_8 python3_9" RUBY_TARGETS="ruby26" USERLAND="GNU" VIDEO_CARDS="fbdev dummy v4l" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CC, CPPFLAGS, CTARGET, CXX, INSTALL_MASK, LC_ALL, LINGUAS, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RUSTFLAGS
Comment 1 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2021-05-24 07:12:15 UTC
Could you try without sandbox?  Note that you need to disable both sandbox and usersandbox.
Comment 2 Rolf Eike Beer archtester 2021-07-11 05:56:10 UTC
Same with 0.31.0 on sparc.
Comment 3 Marek Szuba archtester gentoo-dev 2021-07-29 08:05:50 UTC
Same with 0.31.1 on riscv. Disabling sandbox and usersandbox doesn't help.
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-10-16 00:22:55 UTC
(In reply to Michał Górny from comment #1)
> Could you try without sandbox?  Note that you need to disable both sandbox
> and usersandbox.

Yeah, this avoids all the static ELF spam (which upsets the test looking for specific output).

(Related: https://github.com/gentoo/sandbox/commit/99e318c1a2640091204f970a2e9ff4bdc238980d.)

But the failure still occurs.


tests.patcher_test.test_fork_after_monkey_patch ... Program /var/tmp/portage/dev-python/eventlet-0.32.0/work/eventlet-0.32.0/tests/isolated/patcher_fork_after_monkey_patch.py output:
---
Traceback (most recent call last):
  File "/var/tmp/portage/dev-python/eventlet-0.32.0/work/eventlet-0.32.0/tests/isolated/patcher_fork_after_monkey_patch.py", line 49, in <module>
    check(2, threading, 'post-fork patched')
  File "/var/tmp/portage/dev-python/eventlet-0.32.0/work/eventlet-0.32.0/tests/isolated/patcher_fork_after_monkey_patch.py", line 7, in check
    assert len(mod._active) == n, 'Expected {} {} threads, got {}'.format(n, tag, mod._active)
AssertionError: Expected 2 post-fork patched threads, got {281473441758544: <_MainThread(MainThread, started 281473441758544)>}

---
FAIL

======================================================================
FAIL: tests.patcher_test.test_fork_after_monkey_patch
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python3.8/site-packages/nose/case.py", line 197, in runTest
    self.test(*self.arg)
  File "/var/tmp/portage/dev-python/eventlet-0.32.0/work/eventlet-0.32.0/tests/patcher_test.py", line 521, in test_fork_after_monkey_patch
    tests.run_isolated('patcher_fork_after_monkey_patch.py')
  File "/var/tmp/portage/dev-python/eventlet-0.32.0/work/eventlet-0.32.0/tests/__init__.py", line 381, in run_isolated
    run_python(prefix + path, **kwargs)
  File "/var/tmp/portage/dev-python/eventlet-0.32.0/work/eventlet-0.32.0/tests/__init__.py", line 374, in run_python
    assert ok, 'Expected single line "pass" in stdout'
AssertionError: Expected single line "pass" in stdout

----------------------------------------------------------------------
Ran 424 tests in 232.023s

FAILED (SKIP=94, failures=1)
 * ERROR: dev-python/eventlet-0.32.0::gentoo fail
Comment 5 Alex Fan archtester 2021-11-29 08:27:11 UTC
still happen in 0.32.0-r1

> AssertionError: Expected 2 post-fork patched threads, got {281473724506128: <_MainThread(MainThread, started 281473724506128)>}

This seems to be caused by timeout. the threads don't have enough time to proceed.

in tests/isolated/patcher_fork_after_monkey_patch.py

16  import threading
17  _threading = eventlet.patcher.original('threading')
18  import eventlet.green.threading
19
20  def target():
21>     eventlet.sleep(0.1)

changing eventlet.sleep(0.1) to eventlet.sleep(0.5) will make test pass
Comment 6 Larry the Git Cow gentoo-dev 2021-11-29 17:15:28 UTC
The bug has been closed via the following commit(s):

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

commit e79e0ffb4eea5af7be454acf860421357ce8e2c9
Author:     Arthur Zamarin <arthurzam@gentoo.org>
AuthorDate: 2021-11-29 17:08:29 +0000
Commit:     Arthur Zamarin <arthurzam@gentoo.org>
CommitDate: 2021-11-29 17:15:19 +0000

    dev-python/eventlet: increase test timeout
    
    Thanks to Alex Fan for finding the issue
    By Dakon's request, timeout increased to 5.0
    No revbump as change is for test only file
    
    Closes: https://bugs.gentoo.org/791748
    Suggested-by: Alex Fan <alex.fan.q@gmail.com>
    Signed-off-by: Arthur Zamarin <arthurzam@gentoo.org>

 dev-python/eventlet/eventlet-0.32.0-r1.ebuild | 7 +++++++
 dev-python/eventlet/eventlet-0.33.0.ebuild    | 7 +++++++
 2 files changed, 14 insertions(+)