Kann nichts über pip installieren

Probleme bei der Installation?
Antworten
shIxx
User
Beiträge: 22
Registriert: Sonntag 13. Oktober 2019, 16:11

Hallo an die Community,

bei mir ist ein eigenartiges Problem aufgetaucht das wahrscheinlich was mit der Konfiguration von Python zu tun hat.
Eines vorweg ich bin kein IT-ler/Programmierer. Alles lief wunderbar bis ich neulich versucht habe die manim-Bibliothek von 1blue3braun (vlt kennt jemand seinen YouTube Kannal) zu installieren. Da gibt es zum einen die originale Library von 1b3b und eine Community Version die regelmäßiger weiterentwickelt wird. Letzteres wollte ich installieren. https://github.com/ManimCommunity/manim/
Das stellte sich irgendwie als komplizierter raus als ich dachte https://manimce.readthedocs.io/en/lates ... ation.html.
Naja auf jeden Fall ist seither irgendwas mit meinem Python und dem pip install zerschossen.

Einige Beispiele:
pygame

Code: Alles auswählen

PS C:\Users\thoma\Documents\Python> pip install pygame
Collecting pygame
  Using cached pygame-1.9.6.tar.gz (3.2 MB)
    ERROR: Command errored out with exit status 1:
     command: 'c:\users\thoma\appdata\local\programs\python\python39\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\thoma\\AppData\\Local\\Temp\\pip-install-o8iy8lsq\\pygame\\setup.py'"'"'; __file__='"'"'C:\\Users\\thoma\\AppData\\Local\\Temp\\pip-install-o8iy8lsq\\pygame\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base 'C:\Users\thoma\AppData\Local\Temp\pip-pip-egg-info-bs01_2yw'
         cwd: C:\Users\thoma\AppData\Local\Temp\pip-install-o8iy8lsq\pygame\
    Complete output (17 lines):


    WARNING, No "Setup" File Exists, Running "buildconfig/config.py"
    Using WINDOWS configuration...


    Download prebuilts to "prebuilt_downloads" and copy to "./prebuilt-x64"? [Y/n]Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "C:\Users\thoma\AppData\Local\Temp\pip-install-o8iy8lsq\pygame\setup.py", line 194, in <module>
        buildconfig.config.main(AUTO_CONFIG)
      File "C:\Users\thoma\AppData\Local\Temp\pip-install-o8iy8lsq\pygame\buildconfig\config.py", line 210, in main
        deps = CFG.main(**kwds)
      File "C:\Users\thoma\AppData\Local\Temp\pip-install-o8iy8lsq\pygame\buildconfig\config_win.py", line 576, in main
        and download_win_prebuilt.ask(**download_kwargs):
      File "C:\Users\thoma\AppData\Local\Temp\pip-install-o8iy8lsq\pygame\buildconfig\download_win_prebuilt.py", line 302, in ask
        reply = raw_input(
    EOFError: EOF when reading a line
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
numpy

Code: Alles auswählen

PS C:\Users\thoma\Documents\Python> pip install numpy
Collecting numpy
  Using cached numpy-1.19.2.zip (7.3 MB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... error
    ERROR: Command errored out with exit status 1:
     command: 'c:\users\thoma\appdata\local\programs\python\python39\python.exe' 'c:\users\thoma\appdata\local\programs\python\python39\lib\site-packages\pip\_vendor\pep517\_in_process.py' prepare_metadata_for_build_wheel 'C:\Users\thoma\AppData\Local\Temp\tmp8w04o82k'
         cwd: C:\Users\thoma\AppData\Local\Temp\pip-install-47xluk71\numpy
    Complete output (200 lines):
    Running from numpy source directory.
    setup.py:470: UserWarning: Unrecognized setuptools command, proceeding with generating Cython sources and expanding templates
      run_build = parse_setuppy_commands()
    Processing numpy/random\_bounded_integers.pxd.in
    Processing numpy/random\bit_generator.pyx
    Processing numpy/random\mtrand.pyx
    Processing numpy/random\_bounded_integers.pyx.in
    Processing numpy/random\_common.pyx
    Processing numpy/random\_generator.pyx
    Processing numpy/random\_mt19937.pyx
    Processing numpy/random\_pcg64.pyx
    Processing numpy/random\_philox.pyx
    Processing numpy/random\_sfc64.pyx
    Cythonizing sources
    blas_opt_info:
    blas_mkl_info:
    No module named 'numpy.distutils._msvccompiler' in numpy.distutils; trying from distutils
    customize MSVCCompiler
      libraries mkl_rt not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    blis_info:
      libraries blis not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    openblas_info:
      libraries openblas not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
    get_default_fcompiler: matching types: '['gnu', 'intelv', 'absoft', 'compaqv', 'intelev', 'gnu95', 'g95', 'intelvem', 'intelem', 'flang']'       
    customize GnuFCompiler
    Could not locate executable g77
    Could not locate executable f77
    customize IntelVisualFCompiler
    Could not locate executable ifort
    Could not locate executable ifl
    customize AbsoftFCompiler
    Could not locate executable f90
    customize CompaqVisualFCompiler
    Could not locate executable DF
    customize IntelItaniumVisualFCompiler
    Could not locate executable efl
    customize Gnu95FCompiler
    Could not locate executable gfortran
    Could not locate executable f95
    customize G95FCompiler
    Could not locate executable g95
    customize IntelEM64VisualFCompiler
    customize IntelEM64TFCompiler
    Could not locate executable efort
    Could not locate executable efc
    customize PGroupFlangCompiler
    Could not locate executable flang
    don't know how to compile Fortran code on platform 'nt'
      NOT AVAILABLE

    atlas_3_10_blas_threads_info:
    Setting PTATLAS=ATLAS
      libraries tatlas not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    atlas_3_10_blas_info:
      libraries satlas not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    atlas_blas_threads_info:
    Setting PTATLAS=ATLAS
      libraries ptf77blas,ptcblas,atlas not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    atlas_blas_info:
      libraries f77blas,cblas,atlas not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    accelerate_info:
      NOT AVAILABLE

    C:\Users\thoma\AppData\Local\Temp\pip-install-47xluk71\numpy\numpy\distutils\system_info.py:1914: UserWarning:
        Optimized (vendor) Blas libraries are not found.
        Falls back to netlib Blas library which has worse performance.
        A better performance should be easily gained by switching
        Blas library.
      if self._calc_info(blas):
    blas_info:
      libraries blas not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    C:\Users\thoma\AppData\Local\Temp\pip-install-47xluk71\numpy\numpy\distutils\system_info.py:1914: UserWarning:
        Blas (http://www.netlib.org/blas/) libraries not found.
        Directories to search for the libraries can be specified in the
        numpy/distutils/site.cfg file (section [blas]) or by setting
        the BLAS environment variable.
      if self._calc_info(blas):
    blas_src_info:
      NOT AVAILABLE

    C:\Users\thoma\AppData\Local\Temp\pip-install-47xluk71\numpy\numpy\distutils\system_info.py:1914: UserWarning:
        Blas (http://www.netlib.org/blas/) sources not found.
        Directories to search for the sources can be specified in the
        numpy/distutils/site.cfg file (section [blas_src]) or by setting
        the BLAS_SRC environment variable.
      if self._calc_info(blas):
      NOT AVAILABLE

    non-existing path in 'numpy\\distutils': 'site.cfg'
    lapack_opt_info:
    lapack_mkl_info:
      libraries mkl_rt not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    openblas_lapack_info:
      libraries openblas not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    openblas_clapack_info:
      libraries openblas,lapack not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    flame_info:
      libraries flame not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    atlas_3_10_threads_info:
    Setting PTATLAS=ATLAS
      libraries lapack_atlas not found in c:\users\thoma\appdata\local\programs\python\python39\lib
      libraries tatlas,tatlas not found in c:\users\thoma\appdata\local\programs\python\python39\lib
      libraries lapack_atlas not found in C:\
      libraries tatlas,tatlas not found in C:\
      libraries lapack_atlas not found in c:\users\thoma\appdata\local\programs\python\python39\libs
      libraries tatlas,tatlas not found in c:\users\thoma\appdata\local\programs\python\python39\libs
    <class 'numpy.distutils.system_info.atlas_3_10_threads_info'>
      NOT AVAILABLE

    atlas_3_10_info:
      libraries lapack_atlas not found in c:\users\thoma\appdata\local\programs\python\python39\lib
      libraries satlas,satlas not found in c:\users\thoma\appdata\local\programs\python\python39\lib
      libraries lapack_atlas not found in C:\
      libraries satlas,satlas not found in C:\
      libraries lapack_atlas not found in c:\users\thoma\appdata\local\programs\python\python39\libs
      libraries satlas,satlas not found in c:\users\thoma\appdata\local\programs\python\python39\libs
    <class 'numpy.distutils.system_info.atlas_3_10_info'>
      NOT AVAILABLE

    atlas_threads_info:
    Setting PTATLAS=ATLAS
      libraries lapack_atlas not found in c:\users\thoma\appdata\local\programs\python\python39\lib
      libraries ptf77blas,ptcblas,atlas not found in c:\users\thoma\appdata\local\programs\python\python39\lib
      libraries lapack_atlas not found in C:\
      libraries ptf77blas,ptcblas,atlas not found in C:\
      libraries lapack_atlas not found in c:\users\thoma\appdata\local\programs\python\python39\libs
      libraries ptf77blas,ptcblas,atlas not found in c:\users\thoma\appdata\local\programs\python\python39\libs
    <class 'numpy.distutils.system_info.atlas_threads_info'>
      NOT AVAILABLE

    atlas_info:
      libraries lapack_atlas not found in c:\users\thoma\appdata\local\programs\python\python39\lib
      libraries f77blas,cblas,atlas not found in c:\users\thoma\appdata\local\programs\python\python39\lib
      libraries lapack_atlas not found in C:\
      libraries f77blas,cblas,atlas not found in C:\
      libraries lapack_atlas not found in c:\users\thoma\appdata\local\programs\python\python39\libs
      libraries f77blas,cblas,atlas not found in c:\users\thoma\appdata\local\programs\python\python39\libs
    <class 'numpy.distutils.system_info.atlas_info'>
      NOT AVAILABLE

    lapack_info:
      libraries lapack not found in ['c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\lib', 'C:\\', 'c:\\users\\thoma\\appdata\\local\\programs\\python\\python39\\libs']
      NOT AVAILABLE

    C:\Users\thoma\AppData\Local\Temp\pip-install-47xluk71\numpy\numpy\distutils\system_info.py:1748: UserWarning:
        Lapack (http://www.netlib.org/lapack/) libraries not found.
        Directories to search for the libraries can be specified in the
        numpy/distutils/site.cfg file (section [lapack]) or by setting
        the LAPACK environment variable.
      return getattr(self, '_calc_info_{}'.format(name))()
    lapack_src_info:
      NOT AVAILABLE

    C:\Users\thoma\AppData\Local\Temp\pip-install-47xluk71\numpy\numpy\distutils\system_info.py:1748: UserWarning:
        Lapack (http://www.netlib.org/lapack/) sources not found.
        Directories to search for the sources can be specified in the
        numpy/distutils/site.cfg file (section [lapack_src]) or by setting
        the LAPACK_SRC environment variable.
      return getattr(self, '_calc_info_{}'.format(name))()
      NOT AVAILABLE

    numpy_linalg_lapack_lite:
      FOUND:
        language = c
        define_macros = [('HAVE_BLAS_ILP64', None), ('BLAS_SYMBOL_SUFFIX', '64_')]

    c:\users\thoma\appdata\local\programs\python\python39\lib\distutils\dist.py:274: UserWarning: Unknown distribution option: 'define_macros'       
      warnings.warn(msg)
    running dist_info
    running build_src
    build_src
    building py_modules sources
    creating build
    creating build\src.win-amd64-3.9
    creating build\src.win-amd64-3.9\numpy
    creating build\src.win-amd64-3.9\numpy\distutils
    building library "npymath" sources
    error: Microsoft Visual C++ 14.0 is required. Get it with "Build Tools for Visual Studio": https://visualstudio.microsoft.com/downloads/
    ----------------------------------------
ERROR: Command errored out with exit status 1: 'c:\users\thoma\appdata\local\programs\python\python39\python.exe' 'c:\users\thoma\appdata\local\programs\python\python39\lib\site-packages\pip\_vendor\pep517\_in_process.py' prepare_metadata_for_build_wheel 'C:\Users\thoma\AppData\Local\Temp\tmp8w04o82k' Check the logs for full command output.
Ständig kommt dieser Error

Code: Alles auswählen

ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output
Wenn ich wüsste, wo diese Log files sind, würde ich sie hier Posten.


Dies habe ich probiert aber ohne Erfolg.
1.)

Code: Alles auswählen

pip install --upgrade setuptools
pip install --upgrade pip
pip install --upgrade pip --no-cache-dir
2.)
Habe dann Python 3.8 deinstalliert und das neuste Python 3.9 installiert. Haken bei "zu Path hinzufügen" gesetzt.
Dabei festgestellt, dass ich im ordner C: und in Programme (x86) noch jeweils ein Python Ordner hatte mit einer 32 Bit Version. Keine Ahnung wie die dahin kommen aber habe dann alles manuell gelöscht was noch mit Python 3.8 zu tun hatte.

3.)
Unter den Benutzervariablen habe ich nachgeschaut ob alles passt und es scheint zu passen.
Unter path steht
  • C:\Users\thoma\AppData\Local\Programs\Python\Python39\Scripts\
    C:\Users\thoma\AppData\Local\Programs\Python\Python39\
unter den "Systemvariablen" stand noch irgendwas von Python 3.8. Diese habe ich gelöscht.

4.)
Daraufhin hab ich Python 3.9 nochmal deinstalliert und wieder (sauber nach einem Neustart) installiert.


OffTopic:
Ne, ich bin nicht zu dumm meinen Namen zu schreiben. Habe mich beim erstmaligen installieren von diesem Windows 10 vertippt und jetzt, wenn ich den Rechner neu aufsetzen möchte, synchronisiert er das sobald ich mich mit dem Microsoft Konto anmelde und mein Admin Benutzer heißt jetzt auf alle Ewigkeit "thoma" ohne "s". Keine Ahnuung wie ich das ändern kann. Falls jemand es Weiß, kann er es mir gerne verraten aber ich möchte nicht zu sehr vom eigentlichem Thema abweichen.
Zuletzt geändert von shIxx am Donnerstag 22. Oktober 2020, 15:16, insgesamt 1-mal geändert.
Benutzeravatar
sparrow
User
Beiträge: 4144
Registriert: Freitag 17. April 2009, 10:28

Erst einmal würde ich statt der Powershell die normale Kommandozeile versuchen.
Und wenn du dir unsicher bist, welcher Interpreter verwendet wird, dann rufe pip als Modul auf:

Code: Alles auswählen

\pfad\zur\python.exe -m pip ...
shIxx
User
Beiträge: 22
Registriert: Sonntag 13. Oktober 2019, 16:11

sparrow hat geschrieben: Donnerstag 22. Oktober 2020, 15:15 Erst einmal würde ich statt der Powershell die normale Kommandozeile versuchen.
Und wenn du dir unsicher bist, welcher Interpreter verwendet wird, dann rufe pip als Modul auf:
Ich benutze die Powershell weil sie da so praktisch in VS Code unten dran hängt und bisher gab es nie Probleme. Auch jetzt nicht . Nur wenn ich was über pip installieren möchte.
Habe auch die Powershell als Administrator ausgeführt und die oben genannten Zeilen eingetippt und das Resultat ist das gleiche.
Zum Beispiel

Code: Alles auswählen

pip install --upgrade pip
Requirement already up-to-date: pip in c:\users\thoma\appdata\local\programs\python\python39\lib\site-packages (20.2.4)
Also pip ist auf dem neusten Stannd un der Interpreter ist Python 3.9.0 64Bit so wird mir das unten links in VS Code angezeigt.

EDIT:
Habe es mit der Kommandozeile versucht und das Resultat ist genau das selbe!
Benutzeravatar
__blackjack__
User
Beiträge: 12984
Registriert: Samstag 2. Juni 2018, 10:21
Wohnort: 127.0.0.1
Kontaktdaten:

@shIxx: Du versuchst Sachen zu installieren für die es für Deine Python-Version nichts vorkompiliertes gibt. Also werden die Quelltexte herundergeladen und Du müsstest alles Notwendige installiert haben, damit diese Erweiterungen bei Dir auf dem Rechner kompiliert werden können. Also einen C-Compiler und alle abhängigen Bibliotheken + deren Entwicklungsdateien (Header und so).

Wahrscheinlich ist Python 3.9 einfach noch zu neu. Also entweder mit Python 3.8 arbeiten, oder warten bis es die Packages für 3.9 vorkompiliert gibt, oder alles nötige machen, damit das auf Deinem System kompiliert werden kann. Letzteres ist für Anfänger unter Windows eher nicht zu empfehlen.
“Most people find the concept of programming obvious, but the doing impossible.” — Alan J. Perlis
shIxx
User
Beiträge: 22
Registriert: Sonntag 13. Oktober 2019, 16:11

__blackjack__ hat geschrieben: Donnerstag 22. Oktober 2020, 17:17 Wahrscheinlich ist Python 3.9 einfach noch zu neu. Also entweder mit Python 3.8 arbeiten, oder warten bis es die Packages für 3.9 vorkompiliert gibt, oder alles nötige machen, damit das auf Deinem System kompiliert werden kann. Letzteres ist für Anfänger unter Windows eher nicht zu empfehlen.
Meinst du damit das zB. Pip install numpy nicht geht weil pip unter python 3.9 keine kompilierte Version von numpy hat?
Das währe aber komisch weil es unter 3.8 nach dieser Sache (versuchte Installation von dieser Bibliothek, wie Anfangs erwähnt) nicht mehr ging. Davor ging pip einwandfreie.

Ich glaube dieser "verpfuschte installationversuch" hat irgendwas Manipuliert. Wie gesagt bin kein IT'ler.
Benutzeravatar
__blackjack__
User
Beiträge: 12984
Registriert: Samstag 2. Juni 2018, 10:21
Wohnort: 127.0.0.1
Kontaktdaten:

@shIxx: Das kann man ja einfach nachschauen. Numpy gibt es vorkompiliert für Python 3.6 bis 3.8. Für 3.9 nicht: https://pypi.org/project/numpy/#files
“Most people find the concept of programming obvious, but the doing impossible.” — Alan J. Perlis
shIxx
User
Beiträge: 22
Registriert: Sonntag 13. Oktober 2019, 16:11

Ok ich werde mal Probieren wieder Python 3.8 zu installieren und gebe dann bescheid !
shIxx
User
Beiträge: 22
Registriert: Sonntag 13. Oktober 2019, 16:11

__blackjack__ hat geschrieben: Donnerstag 22. Oktober 2020, 17:50 @shIxx: Das kann man ja einfach nachschauen. Numpy gibt es vorkompiliert für Python 3.6 bis 3.8. Für 3.9 nicht: https://pypi.org/project/numpy/#files
Vielen Dank es läuft jetzt wieder mit Python 3.8.6.

Was ich nur nicht verstehe ist, dass mir nach der Installation dieser manim-Bibliothek, pip unter 3.8.5 nicht mehr ging UND das mit dem selben Error den es dann auch unter 3.9 gab. 🤔

Egal jetzt läufts und ich kann meine Übungsaufgaben weiter machen,... Danke jeden für die Mühe!

EDIT:
Kann ich hier den Thread als [solved] markieren?
Antworten