Toutes mes réponses sur les forums

5 sujets de 1 à 5 (sur un total de 5)
  • Auteur
    Messages
  • #1351
    Thib
    Participant

    Bonjour,

    Effectivement comment ce passe tout export après validation via le vérificateur ?

    Cdt,

    #1348
    Thib
    Participant

    Correctif : Ajouter les librairies suivantes

    sudo apt install libpq-dev python3-dev gcc

    #1344
    Thib
    Participant

    Je récupère désormais un erreur psycopg2 :

    Installing collected packages: psycopg2
    Running setup.py install for psycopg2 ... error
    ERROR: Command errored out with exit status 1:
    command: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-5xcihcyy/psycopg2_b232b8f59c2740a586040461cb5807e2/setup.py'"'"'; __file__='"'"'/tmp/pip-install-5xcihcyy/psycopg2_b232b8f59c2740a586040461cb5807e2/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-f_rd8gjt/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.7/psycopg2
    cwd: /tmp/pip-install-5xcihcyy/psycopg2_b232b8f59c2740a586040461cb5807e2/
    Complete output (38 lines):
    running install
    running build
    running build_py
    creating build
    creating build/lib.linux-x86_64-3.7
    creating build/lib.linux-x86_64-3.7/psycopg2
    copying lib/extras.py -> build/lib.linux-x86_64-3.7/psycopg2
    copying lib/errorcodes.py -> build/lib.linux-x86_64-3.7/psycopg2
    copying lib/_ipaddress.py -> build/lib.linux-x86_64-3.7/psycopg2
    copying lib/_range.py -> build/lib.linux-x86_64-3.7/psycopg2
    copying lib/errors.py -> build/lib.linux-x86_64-3.7/psycopg2
    copying lib/extensions.py -> build/lib.linux-x86_64-3.7/psycopg2
    copying lib/_json.py -> build/lib.linux-x86_64-3.7/psycopg2
    copying lib/tz.py -> build/lib.linux-x86_64-3.7/psycopg2
    copying lib/sql.py -> build/lib.linux-x86_64-3.7/psycopg2
    copying lib/pool.py -> build/lib.linux-x86_64-3.7/psycopg2
    copying lib/__init__.py -> build/lib.linux-x86_64-3.7/psycopg2
    running build_ext
    building 'psycopg2._psycopg' extension
    creating build/temp.linux-x86_64-3.7
    creating build/temp.linux-x86_64-3.7/psycopg
    x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DPSYCOPG_VERSION=2.9.1 (dt dec pq3 ext lo64) -DPSYCOPG_DEBUG=1 -DPG_VERSION_NUM=110012 -DHAVE_LO64=1 -DPSYCOPG_DEBUG=1 -I/usr/include/python3.7m -I. -I/usr/include/postgresql -I/usr/include/postgresql/11/server -I/usr/include/libxml2 -I/usr/include/mit-krb5 -c psycopg/psycopgmodule.c -o build/temp.linux-x86_64-3.7/psycopg/psycopgmodule.o -Wdeclaration-after-statement
    In file included from psycopg/psycopgmodule.c:28:
    ./psycopg/psycopg.h:35:10: fatal error: Python.h: No such file or directory
    #include <Python.h>
    ^~~~~~~~~~
    compilation terminated.

    It appears you are missing some prerequisite to build the package from source.

    You may install a binary package by installing 'psycopg2-binary' from PyPI.
    If you want to install psycopg2 from source, please install the packages
    required for the build and try again.

    For further information please check the 'doc/src/install.rst' file (also at
    <https://www.psycopg.org/docs/install.html>).

    error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
    ----------------------------------------
    ERROR: Command errored out with exit status 1: /usr/bin/python3 -u -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-5xcihcyy/psycopg2_b232b8f59c2740a586040461cb5807e2/setup.py'"'"'; __file__='"'"'/tmp/pip-install-5xcihcyy/psycopg2_b232b8f59c2740a586040461cb5807e2/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(__file__) if os.path.exists(__file__) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-f_rd8gjt/install-record.txt --single-version-externally-managed --compile --install-headers /usr/local/include/python3.7/psycopg2 Check the logs for full command output.

    • Cette réponse a été modifiée le il y a 3 années et 2 mois par Thib.
    #1343
    Thib
    Participant

    Autant pour moi il n’était pas installé en root 🙂

    Merci 😉

    #1342
    Thib
    Participant

    J’avais omis de mentionné que j’avais essayé d’installer setuptools.
    Mais il est déjà présent :
    Requirement already satisfied: setuptools in ~/.local/lib/python3.7/site-packages (58.0.4)

5 sujets de 1 à 5 (sur un total de 5)