From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id QImrJnJPh2OdlQAAbAwnHQ (envelope-from ) for ; Wed, 30 Nov 2022 13:41:22 +0100 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id IPm7JXJPh2OJrwAAG6o9tA (envelope-from ) for ; Wed, 30 Nov 2022 13:41:22 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 13D7639242 for ; Wed, 30 Nov 2022 13:41:21 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1p0MOG-0007Jd-ES; Wed, 30 Nov 2022 07:40:40 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p0MOF-0007JS-2V for help-guix@gnu.org; Wed, 30 Nov 2022 07:40:39 -0500 Received: from mail-wr1-x42b.google.com ([2a00:1450:4864:20::42b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1p0MOC-0005S2-TH for help-guix@gnu.org; Wed, 30 Nov 2022 07:40:38 -0500 Received: by mail-wr1-x42b.google.com with SMTP id x17so26861243wrn.6 for ; Wed, 30 Nov 2022 04:40:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:from:to:cc:subject:date:message-id :reply-to; bh=A+nWg/ylUr298Khd5YclIUKsn/n0wr1pv1PMBAui9cA=; b=LbGIeJvOPOanGzXEpqz0mIo2XXRFF3JAlUURDNH9L+XEIq4vkT4Wrbp+8ThzxTqEMu pPIaiuCmeML3VQUXei4Qg5NkmgRbq9yaAqUOBypNXU0WNZXEhalks7FhpMpZAG73vqJf rTs5tW8C/Cw8lN0PbWmcXJMcgt0BoXtIn9F3LrTP37GkpIdma1wV0k2pMDJgpg/rEZ5I jK7rIzp5nXH9gBP7pM7YIQtez5YqWkcxPFvJkH5YXRG3/oWGZnYmCyNMWMCM1GhsF5nd 0VUcowdBbR9LZ8de4oLMWmDttep6c+yFT4whJuDBRGOBLAkWImujsdls9I79wjyrTXuS TOgA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=A+nWg/ylUr298Khd5YclIUKsn/n0wr1pv1PMBAui9cA=; b=FqosH4q+/rviGDtkJ6LNWK5/WmelitUFL607qrUeYnYEmjD9pe1grUHlhZ1yxgdZRy xLZujTDI8M9pZIVX/zg4N8JGCYbz7wBBsxTQmBSSIFTAQsrVeWYr+J77K42JOQ8YD6fT 6i8/5lNJmARWHDXMAZQpHMRsHOvrqi8vQZEWjXp6Gbrw2dLBWxWMb3Q4lBTaRaAEocFo jnPeDT1iBOfUZpBbrqzSH2KYQMAnNge7w/jItdk42F4ON8VdbULySYyOWhrPFQ2VcQ5C vmGb3J1MNDeNIUPjL0TeAaS0YHAr0htGzrApBrIwQ8DkL9q+D85DbDIINg8r962ZE0YE zaDA== X-Gm-Message-State: ANoB5pmVJGcaSlAjjugz6zG/aCvBU95zi+Y1HEcsNKUjYWZHZEkhdkUo Ck2wNL23CixdQ2r2p2rYFExIlBgZOM0= X-Google-Smtp-Source: AA0mqf4KtHe53uRgPluXgMRBWkvxvnThBmbMMiigBIbBQVCtSH8qHUxHm1o6zWB9TXsQZHWFnJ5Avw== X-Received: by 2002:adf:e74b:0:b0:242:8bf:a699 with SMTP id c11-20020adfe74b000000b0024208bfa699mr15456117wrn.55.1669812034073; Wed, 30 Nov 2022 04:40:34 -0800 (PST) Received: from pfiuh07 ([193.48.40.241]) by smtp.gmail.com with ESMTPSA id bg2-20020a05600c3c8200b003a3170a7af9sm2294555wmb.4.2022.11.30.04.40.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 30 Nov 2022 04:40:33 -0800 (PST) From: zimoun To: Wojtek Kosior Cc: mprodrigues@posteo.net, help-guix@gnu.org Subject: Re: Problem loading numpy and other on a venv in a guix system In-Reply-To: <20221130094733.5a91acf6@koszkonutek-tmp.pl.eu.org> References: <3ee102246f0716dc9e4d1330062639ca@posteo.net> <86r0xk6esw.fsf@gmail.com> <20221130094733.5a91acf6@koszkonutek-tmp.pl.eu.org> Date: Wed, 30 Nov 2022 13:37:43 +0100 Message-ID: <87lenssjmw.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2a00:1450:4864:20::42b; envelope-from=zimon.toutoune@gmail.com; helo=mail-wr1-x42b.google.com X-Spam_score_int: -19 X-Spam_score: -2.0 X-Spam_bar: -- X-Spam_report: (-2.0 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URI_HEX=0.1 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-guix@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+larch=yhetil.org@gnu.org Sender: help-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1669812082; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=A+nWg/ylUr298Khd5YclIUKsn/n0wr1pv1PMBAui9cA=; b=FN6nb52+COybtgkXh48bSketo3UKSU8jCybXuTK02yXYFDV4vNh2XEn8BOYbtj7Cir3zJw zUP+s/+4ZH5WcG/a2iTQIGTx++iNo5XduuDsSSB7NDokYLYNlsps5QHHCdi9Eqsxe6jb9l 1S9KK2I0wNkaWCAISxK8qkmSe0b7cX/BMf5NXFh2Egoe9J7W6fcKmlMWUj1tBEToiAJK6Q jUGIjjiJQ/zk3pYwTy/T3/GVPH50uckxqWTeJcOKtWnQKPS/jbI2y7QdEqm7NLPXabXpjc oxRshSEUNfON8vWQ79f9Da/V3Da61yZdDykeM96PiDzOYGa65mxhCBWDGj0Kkw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1669812082; a=rsa-sha256; cv=none; b=Slm/3FzSTTahjja+foGlzTvNk8g0jdmJ5kJBnNz2fSINEKymk7VX93tumGnqh2QOeit7oW rIO/gWD//psn2wnqJON1si6QeOK49qf9Wkyd945CDvwSbqKT3P9cHIdRNdq/WqietxiWMX 0bfCckVyqmX9RFz8Isj2Be7jDfd2lc+wOBKyOSsPcU1h9ipwbyT+cHYji8PcqZZ64Yt1Mf IbUAO9sL+8l3lOoTEux/U1dFmPzQaLPVMAwMe14hDe8rB4Cpt1WowTGp73T9xTbCm4oQtB q4KfsAT/cmKxpWVkNsHa3rI50fhjAezGpt5vw/T5lpS0uPccTUGXi2+jxN8VOA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=LbGIeJvO; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Spam-Score: -5.06 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=LbGIeJvO; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of "help-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="help-guix-bounces+larch=yhetil.org@gnu.org" X-Migadu-Queue-Id: 13D7639242 X-Spam-Score: -5.06 X-Migadu-Scanner: scn0.migadu.com X-TUID: Npymhy1hJ+wr Hi, On Wed, 30 Nov 2022 at 09:47, Wojtek Kosior via wrote: cd /tmp/ > guix shell python python-virtualenv coreutils > virtualenv -p python3 somedirectory > . ./somedirectory/bin/activate > pip install numpy python3 -c 'import numpy' leads to, --8<---------------cut here---------------start------------->8--- Traceback (most recent call last): File "/tmp/somedirectory/lib/python3.9/site-packages/numpy/core/__init__.= py", line 23, in from . import multiarray File "/tmp/somedirectory/lib/python3.9/site-packages/numpy/core/multiarra= y.py", line 10, in from . import overrides File "/tmp/somedirectory/lib/python3.9/site-packages/numpy/core/overrides= .py", line 6, in from numpy.core._multiarray_umath import ( ImportError: libz.so.1: cannot open shared object file: No such file or dir= ectory During handling of the above exception, another exception occurred: Traceback (most recent call last): File "", line 1, in File "/tmp/somedirectory/lib/python3.9/site-packages/numpy/__init__.py", = line 140, in from . import core File "/tmp/somedirectory/lib/python3.9/site-packages/numpy/core/__init__.= py", line 49, in raise ImportError(msg) ImportError:=20 IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE! Importing the numpy C-extensions failed. This error can happen for many reasons, often due to issues with your setup or how NumPy was installed. We have compiled some common reasons and troubleshooting tips at: https://numpy.org/devdocs/user/troubleshooting-importerror.html Please note and check the following: * The Python version is: Python3.9 from "/tmp/somedirectory/bin/python3" * The NumPy version is: "1.23.5" and make sure that they are the versions you expect. Please carefully study the documentation linked above for further help. Original error was: libz.so.1: cannot open shared object file: No such file= or directory --8<---------------cut here---------------end--------------->8--- That=E2=80=99s because the Numpy from pip is linked to system-wide library, --8<---------------cut here---------------start------------->8--- $ ldd somedirectory/lib/python3.9/site-packages/numpy/core/_multiarray_umat= h.cpython-39-x86_64-linux-gnu.so linux-vdso.so.1 (0x00007ffde12e0000) libopenblas64_p-r0-742d56dc.3.20.so =3D> /tmp/somedirectory/lib/python3.9/= site-packages/numpy/core/../../numpy.libs/libopenblas64_p-r0-742d56dc.3.20.= so (0x00007f6f1223d000) libm.so.6 =3D> /lib/x86_64-linux-gnu/libm.so.6 (0x00007f6f120dd000) libpthread.so.0 =3D> /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f6f120b= a000) libc.so.6 =3D> /lib/x86_64-linux-gnu/libc.so.6 (0x00007f6f11ec8000) /lib64/ld-linux-x86-64.so.2 (0x00007f6f1481a000) libgfortran-040039e1.so.5.0.0 =3D> /tmp/somedirectory/lib/python3.9/site-p= ackages/numpy/core/../../numpy.libs/libgfortran-040039e1.so.5.0.0 (0x00007f= 6f11a3b000) libquadmath-96973f99.so.0.0.0 =3D> /tmp/somedirectory/lib/python3.9/site-p= ackages/numpy/core/../../numpy.libs/libquadmath-96973f99.so.0.0.0 (0x00007f= 6f117fc000) libz.so.1 =3D> /lib/x86_64-linux-gnu/libz.so.1 (0x00007f6f117e0000) libgcc_s.so.1 =3D> /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f6f117c5000) --8<---------------cut here---------------end--------------->8--- and they are not found. Well, if you are running Guix on foreign distro, you can manually fix the issue with this =E2=80=9Cmissing=E2=80=9D = libz library by setting LD_LIBRARY_PATH=3D/lib/x86_64-linux-gnu/. But you get another issue: --8<---------------cut here---------------start------------->8--- $ LD_LIBRARY_PATH=3D/lib/x86_64-linux-gnu/ python3 -c 'import numpy' python3: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.33' not found (r= equired by /gnu/store/lvip6h5pamjwmvnkwg60sjb63ph8698k-python-3.9.9/lib/lib= python3.9.so.1.0) python3: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found (r= equired by /gnu/store/lvip6h5pamjwmvnkwg60sjb63ph8698k-python-3.9.9/lib/lib= python3.9.so.1.0) --8<---------------cut here---------------end--------------->8--- Well, I do not know if the Guix package =E2=80=9Cpython-virtualenv=E2=80=9D= is working in =E2=80=9Cguix shell=E2=80=9D. Cheers, simon