Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] Python upgrade: dev-python/certifi fails to emerge
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
sidamos
Apprentice
Apprentice


Joined: 16 Dec 2007
Posts: 246

PostPosted: Wed Jun 05, 2024 1:45 pm    Post subject: [SOLVED] Python upgrade: dev-python/certifi fails to emerge Reply with quote

My last emerge was about 2 months ago. This means, I am still on the previous profile and the Python upgrade will be done.

Before the upgrade, I removed all Python version use flags and then emerge added a couple of them back before the actual upgrade.

I have no blockers, but dev-python/certifi fails to emerge during the upgrade.

Code:

>>> Failed to emerge dev-python/certifi-3021.3.16-r4, Log file:

>>>  '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/temp/build.log'

 * Messages for package dev-python/certifi-3021.3.16-r4:

 * ERROR: dev-python/certifi-3021.3.16-r4::gentoo failed (compile phase):
 *   Wheel build failed
 *
 * Call stack:
 *     ebuild.sh, line  136:  Called src_compile
 *   environment, line 4033:  Called distutils-r1_src_compile
 *   environment, line 1940:  Called _distutils-r1_run_foreach_impl 'python_compile'
 *   environment, line  761:  Called python_foreach_impl 'distutils-r1_run_phase' 'python_compile'
 *   environment, line 3653:  Called multibuild_foreach_variant '_python_multibuild_wrapper' 'distutils-r1_run_phase' 'python_compile'
 *   environment, line 3202:  Called _multibuild_run '_python_multibuild_wrapper' 'distutils-r1_run_phase' 'python_compile'
 *   environment, line 3200:  Called _python_multibuild_wrapper 'distutils-r1_run_phase' 'python_compile'
 *   environment, line 1244:  Called distutils-r1_run_phase 'python_compile'
 *   environment, line 1924:  Called python_compile
 *   environment, line 3448:  Called distutils-r1_python_compile
 *   environment, line 1739:  Called distutils_pep517_install '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/work/certifi-system-store-3021.3.16-python3_11/install'
 *   environment, line 2324:  Called die
 * The specific snippet of code:
 *       [[ -n ${wheel} ]] || die "No wheel name returned";
 *
 * If you need support, post the output of `emerge --info '=dev-python/certifi-3021.3.16-r4::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=dev-python/certifi-3021.3.16-r4::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/temp/environment'.
 * Working directory: '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/work/certifi-system-store-3021.3.16'
 * S: '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/work/certifi-system-store-3021.3.16'


The build log:
Code:

 * Package:    dev-python/certifi-3021.3.16-r4:0
 * Repository: gentoo
 * Maintainer: python@gentoo.org
 * USE:        abi_x86_64 amd64 elibc_glibc kernel_linux python_targets_python3_11 python_targets_python3_12
 * FEATURES:   network-sandbox preserve-libs sandbox userpriv usersandbox
>>> Unpacking source...
>>> Unpacking certifi-system-store-3021.3.16.gh.tar.gz to /var/tmp/portage/dev-python/certifi-3021.3.16-r4/work
>>> Source unpacked in /var/tmp/portage/dev-python/certifi-3021.3.16-r4/work
>>> Preparing source in /var/tmp/portage/dev-python/certifi-3021.3.16-r4/work/certifi-system-store-3021.3.16 ...
 * Applying certifi-3021.3.16-use-importlib.patch ...
patching file src/certifi/_patch.py
patching file setup.cfg
patching file src/certifi/_patch.py                                                          [ ok ]
 * Build system packages:
 *   dev-python/gpep517            : 16
 *   dev-python/installer          : 0.7.0
 *   dev-python/setuptools         : 69.5.1-r1
 *   dev-python/setuptools-rust    : 1.9.0
 *   dev-python/setuptools-scm     : 8.1.0
 *   dev-python/wheel              : 0.43.0
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/dev-python/certifi-3021.3.16-r4/work/certifi-system-store-3021.3.16 ...
>>> Source configured.
>>> Compiling source in /var/tmp/portage/dev-python/certifi-3021.3.16-r4/work/certifi-system-store-3021.3.16 ...
 * python3_11: running distutils-r1_run_phase python_compile
 *   Building the wheel for certifi-system-store-3021.3.16 via setuptools.build_meta
python3.11 -m gpep517 build-wheel --prefix=/usr --backend setuptools.build_meta --output-fd 3 --wheel-dir /var/tmp/portage/dev-python/certifi-3021.3.16-r4/work/certifi-system-store-3021.3.16-python3_11/wheel
2024-06-05 15:39:11,801 gpep517 INFO Building wheel via backend setuptools.build_meta
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/usr/lib/python3.11/site-packages/gpep517/__main__.py", line 443, in <module>
    sys.exit(main())
             ^^^^^^
  File "/usr/lib/python3.11/site-packages/gpep517/__main__.py", line 439, in main
    return func(args)
           ^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/gpep517/__main__.py", line 229, in build_wheel
    print(build_wheel_impl(args, args.wheel_dir), file=out)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/gpep517/__main__.py", line 221, in build_wheel_impl
    wheel_name = backend.build_wheel(str(wheel_dir), args.config_json)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/setuptools/build_meta.py", line 410, in build_wheel
    return self._build_with_temp_dir(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/setuptools/build_meta.py", line 395, in _build_with_temp_dir
    self.run_setup()
  File "/usr/lib/python3.11/site-packages/setuptools/build_meta.py", line 311, in run_setup
    exec(code, locals())
  File "<string>", line 3, in <module>
  File "/usr/lib/python3.11/site-packages/setuptools/__init__.py", line 104, in setup
    return distutils.core.setup(**attrs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/setuptools/_distutils/core.py", line 146, in setup
    _setup_distribution = dist = klass(attrs)
                                 ^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/setuptools/dist.py", line 307, in __init__
    _Distribution.__init__(self, dist_attrs)
  File "/usr/lib/python3.11/site-packages/setuptools/_distutils/dist.py", line 284, in __init__
    self.finalize_options()
  File "/usr/lib/python3.11/site-packages/setuptools/dist.py", line 657, in finalize_options
    for ep in sorted(loaded, key=by_order):
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/setuptools/dist.py", line 656, in <lambda>
    loaded = map(lambda e: e.load(), filtered)
                           ^^^^^^^^
  File "/usr/lib/python3.11/importlib/metadata/__init__.py", line 202, in load
    module = import_module(match.group('module'))
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1126, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "<frozen importlib._bootstrap>", line 1204, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1176, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1147, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 690, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 940, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/usr/lib/python3.11/site-packages/setuptools_rust/__init__.py", line 1, in <module>
    from .build import build_rust
  File "/usr/lib/python3.11/site-packages/setuptools_rust/build.py", line 28, in <module>
    from .command import RustCommand
  File "/usr/lib/python3.11/site-packages/setuptools_rust/command.py", line 7, in <module>
    from .extension import RustExtension
  File "/usr/lib/python3.11/site-packages/setuptools_rust/extension.py", line 21, in <module>
    from semantic_version import SimpleSpec
ModuleNotFoundError: No module named 'semantic_version'
 * ERROR: dev-python/certifi-3021.3.16-r4::gentoo failed (compile phase):
 *   Wheel build failed
 *
 * Call stack:
 *     ebuild.sh, line  136:  Called src_compile
 *   environment, line 4033:  Called distutils-r1_src_compile
 *   environment, line 1940:  Called _distutils-r1_run_foreach_impl 'python_compile'
 *   environment, line  761:  Called python_foreach_impl 'distutils-r1_run_phase' 'python_compile'
 *   environment, line 3653:  Called multibuild_foreach_variant '_python_multibuild_wrapper' 'distutils-r1_run_phase' 'python_compile'
 *   environment, line 3202:  Called _multibuild_run '_python_multibuild_wrapper' 'distutils-r1_run_phase' 'python_compile'
 *   environment, line 3200:  Called _python_multibuild_wrapper 'distutils-r1_run_phase' 'python_compile'
 *   environment, line 1244:  Called distutils-r1_run_phase 'python_compile'
 *   environment, line 1924:  Called python_compile
 *   environment, line 3448:  Called distutils-r1_python_compile
 *   environment, line 1739:  Called distutils_pep517_install '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/work/certifi-system-store-3021.3.16-python3_11/install'
 *   environment, line 2324:  Called die
 * The specific snippet of code:
 *       [[ -n ${wheel} ]] || die "No wheel name returned";
 *
 * If you need support, post the output of `emerge --info '=dev-python/certifi-3021.3.16-r4::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=dev-python/certifi-3021.3.16-r4::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/temp/environment'.
 * Working directory: '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/work/certifi-system-store-3021.3.16'
 * S: '/var/tmp/portage/dev-python/certifi-3021.3.16-r4/work/certifi-system-store-3021.3.16'


It looks to me as if "ModuleNotFoundError: No module named 'semantic_version'" is the actual error. But that thing is installed:
# equery list "*semantic*"
* Searching for *semantic* ...
[IP-] [ ] dev-python/semantic-version-2.10.0:0

(although with a "-" and not "_")

emerge --info (removed the profile warning):
Code:

Portage 3.0.61 (python 3.11.8-final-0, default/linux/amd64/17.1/desktop/plasma, gcc-13, glibc-2.38-r10, 6.6.21-gentoo-x86_64 x86_64)
=================================================================
System uname: Linux-6.6.21-gentoo-x86_64-x86_64-Intel-R-_Core-TM-_i5-3470S_CPU_@_2.90GHz-with-glibc2.38
KiB Mem:    16078756 total,   2400948 free
KiB Swap:    8388604 total,   7499772 free
Timestamp of repository gentoo: Wed, 05 Jun 2024 05:00:00 +0000
Head commit of repository gentoo: 1452e9a1ae8099a50540a12c56559f415c42db62
sh bash 5.1_p16-r6
ld GNU ld (Gentoo 2.41 p5) 2.41.0
ccache version 4.9.1 [disabled]
app-misc/pax-utils:        1.3.7::gentoo
app-shells/bash:           5.1_p16-r6::gentoo
dev-build/autoconf:        2.71-r7::gentoo
dev-build/automake:        1.16.5-r2::gentoo
dev-build/cmake:           3.28.3::gentoo
dev-build/libtool:         2.4.7-r4::gentoo
dev-build/make:            4.4.1-r1::gentoo
dev-build/meson:           1.4.0-r1::gentoo
dev-java/java-config:      2.3.3-r1::gentoo
dev-lang/perl:             5.38.2-r3::gentoo
dev-lang/python:           3.10.13_p3::gentoo, 3.11.8_p1::gentoo, 3.12.2_p1::gentoo
dev-lang/rust:             1.75.0-r1::gentoo
dev-util/ccache:           4.9.1::gentoo
sys-apps/baselayout:       2.15::gentoo
sys-apps/openrc:           0.54::gentoo
sys-apps/sandbox:          2.38::gentoo
sys-devel/binutils:        2.41-r5::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/clang:           17.0.6::gentoo
sys-devel/gcc:             13.2.1_p20240210::gentoo
sys-devel/gcc-config:      2.11::gentoo
sys-devel/llvm:            17.0.6::gentoo
sys-kernel/linux-headers:  6.6-r1::gentoo (virtual/os-headers)
sys-libs/glibc:            2.38-r10::gentoo
Repositories:

gentoo
    location: /usr/portage
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000
    volatile: True
    sync-rsync-verify-max-age: 3
    sync-rsync-verify-jobs: 1
    sync-rsync-verify-metamanifest: yes
    sync-rsync-extra-opts:

fkmclane
    location: /var/lib/layman/fkmclane
    masters: gentoo
    priority: 0
    volatile: True

x-portage
    location: /usr/local/portage
    masters: gentoo
    priority: 1
    volatile: True

Binary Repositories:

binhost
    priority: 9999
    sync-uri: https://ftp.halifax.rwth-aachen.de/gentoo/releases/amd64/binpackages/17.1/x86-64

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/easy-rsa /usr/share/gnupg/qualified.txt /var/spool/munin-async/.ssh"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php8.2/ext-active/ /etc/php/cgi-php8.2/ext-active/ /etc/php/cli-php8.2/ext-active/ /etc/php/fpm-php8.2/ext-active/ /etc/php/phpdbg-php8.2/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--getbinpkg"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE 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 XDG_STATE_HOME"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-request-signature buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox pkgdir-index-trusted 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"
GENTOO_MIRRORS="ftp://sunsite.informatik.rwth-aachen.de/pub/Linux/gentoo http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/ "
LANG="en_US.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LEX="flex"
LINGUAS="de en"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
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"
SHELL="/bin/bash"
USE="X a52 aac acl acpi activities alsa amd64 apache2 asf avahi branding bzip2 cairo cdda cdr cli crypt cups dbus declarative dga divx dri dts dvb dvd dvdr dvdread eds elogind emboss encode evo exif expat fam fame ffmpeg firefox flac fortran gdbm gif glitz gpm gstreamer gtk gui hal iconv icu imagemagick ipv6 java joystick jpeg jpeg2k kde kwallet lcd lcms ldap libc-omitfp libnotify libtirpc lirc lm_sensors lzo mad mbox mdnsresponder-compat mikmod mjpeg mmx mng mp3 mp4 mpeg mplayer multilib mysql mysqli ncurses networkmanager nls nsplugin ogg opengl openmp openssh pam pango pcre pdf pipewire plasma png policykit ppds pulseaudio qml qt5 quicktime readline screencast sdl seccomp sound spell split-usr sse sse2 ssl startup-notification svg test-rust theora tiff transcode truetype udev unicode upower ups usb v4l v4l2 vcd vdpau vorbis vulkan wayland widgets win32codecs wxwidgets x264 xattr xcb xft xine xml xv xvid zlib" ABI_X86="64" ADA_TARGET="gcc_12" ALSA_CARDS="emu10k1" APACHE2_MODULES="cgid cgi actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_html proxy_http rewrite setenvif so speling status substitute unique_id userdir usertrack vhost_alias python unixd slotmem_shm authn_core authz_core socache_shmcb access_compat xml2enc" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx mmx mmxext popcnt sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 ntrip navcom oceanserver oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 tsip tripmate tnt ublox" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" L10N="de en" LCD_DEVICES="cfontz ncurses text" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-2" POSTGRES_TARGETS="postgres15" PYTHON_SINGLE_TARGET="python3_12" PYTHON_TARGETS="python3_12" RUBY_TARGETS="ruby31 ruby32" VIDEO_CARDS="intel" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipp2p iface geoip fuzzy condition tarpit sysrq proto logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PYTHONPATH, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS


Any help would be greatly appreciated. Thanks!


Last edited by sidamos on Fri Jun 07, 2024 3:23 pm; edited 1 time in total
Back to top
View user's profile Send private message
Hu
Administrator
Administrator


Joined: 06 Mar 2007
Posts: 22648

PostPosted: Wed Jun 05, 2024 2:04 pm    Post subject: Reply with quote

This looks like a duplicate of wheel build failed on every packages broken system?, where I posted a workaround that the thread author indicated resolved the problem. Does that workaround work for you?
Back to top
View user's profile Send private message
sidamos
Apprentice
Apprentice


Joined: 16 Dec 2007
Posts: 246

PostPosted: Wed Jun 05, 2024 2:13 pm    Post subject: Reply with quote

Thanks a lot for the quick reply and workaround!

I would have never thought that setuptools-rust is the issue.

I re-emerged that and then certifi was emerging fine.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum