Ankündigung

Einklappen

Serverwartung 21.2.



Am 21.2. im Laufe des späten Abends wird eine Serverwartung durchgeführt. Das Forum ist dadurch für gut zwei Stunden nicht erreichbar.
Es wird eine Wartungsseite geschaltet.

Mehr anzeigen
Weniger anzeigen

pip Problem - Traceback (most recent call last)...ImportError: cannot import name ...

Einklappen
X
 
  • Filter
  • Zeit
  • Anzeigen
Alles löschen
neue Beiträge

    pip Problem - Traceback (most recent call last)...ImportError: cannot import name ...

    Hallo zusammen,

    habe ein pip-Problem... alles wird einwandfrei installiert, wenn ich dann pip verwenden will kommt dieser Traceback-Fehler... aber seht selbst:
    Code:
    sudo apt-get install dialog python3 python3-dev python3-setuptools unzip build-essential
    Paketlisten werden gelesen... Fertig
    Abhängigkeitsbaum wird aufgebaut.
    Statusinformationen werden eingelesen.... Fertig
    Die folgenden Pakete wurden automatisch installiert und werden nicht mehr benötigt:
      python-cffi python-colorama python-cryptography python-distlib
      python-html5lib python-ndg-httpsclient python-openssl python-ply
      python-pyasn1 python-pycparser python-urllib3 python-wheel
    Verwenden Sie »apt-get autoremove«, um sie zu entfernen.
    Die folgenden zusätzlichen Pakete werden installiert:
      dh-python python3-pkg-resources
    Vorgeschlagene Pakete:
      python3-doc python3-tk python3-venv zip
    Die folgenden NEUEN Pakete werden installiert:
      build-essential dh-python dialog python3 python3-dev python3-pkg-resources
      python3-setuptools unzip
    0 aktualisiert, 8 neu installiert, 0 zu entfernen und 0 nicht aktualisiert.
    Es müssen noch 0 B von 681 kB an Archiven heruntergeladen werden.
    Nach dieser Operation werden 2.931 kB Plattenplatz zusätzlich benutzt.
    Möchten Sie fortfahren? [J/n] j
    Vormals nicht ausgewähltes Paket build-essential wird gewählt.
    (Lese Datenbank ... 44654 Dateien und Verzeichnisse sind derzeit installiert.)
    Vorbereitung zum Entpacken von .../build-essential_11.7_amd64.deb ...
    Entpacken von build-essential (11.7) ...
    Vormals nicht ausgewähltes Paket python3 wird gewählt.
    Vorbereitung zum Entpacken von .../python3_3.4.2-2_amd64.deb ...
    Entpacken von python3 (3.4.2-2) ...
    Vormals nicht ausgewähltes Paket dh-python wird gewählt.
    Vorbereitung zum Entpacken von .../dh-python_1.20141111-2_all.deb ...
    Entpacken von dh-python (1.20141111-2) ...
    Vormals nicht ausgewähltes Paket dialog wird gewählt.
    Vorbereitung zum Entpacken von .../dialog_1.2-20140911-1_amd64.deb ...
    Entpacken von dialog (1.2-20140911-1) ...
    Vormals nicht ausgewähltes Paket python3-dev wird gewählt.
    Vorbereitung zum Entpacken von .../python3-dev_3.4.2-2_amd64.deb ...
    Entpacken von python3-dev (3.4.2-2) ...
    Vormals nicht ausgewähltes Paket python3-pkg-resources wird gewählt.
    Vorbereitung zum Entpacken von .../python3-pkg-resources_5.5.1-1_all.deb ...
    Entpacken von python3-pkg-resources (5.5.1-1) ...
    Vormals nicht ausgewähltes Paket python3-setuptools wird gewählt.
    Vorbereitung zum Entpacken von .../python3-setuptools_5.5.1-1_all.deb ...
    Entpacken von python3-setuptools (5.5.1-1) ...
    Vormals nicht ausgewähltes Paket unzip wird gewählt.
    Vorbereitung zum Entpacken von .../unzip_6.0-16+deb8u2_amd64.deb ...
    Entpacken von unzip (6.0-16+deb8u2) ...
    Trigger für man-db (2.7.0.2-5) werden verarbeitet ...
    Trigger für mime-support (3.58) werden verarbeitet ...
    build-essential (11.7) wird eingerichtet ...
    dialog (1.2-20140911-1) wird eingerichtet ...
    unzip (6.0-16+deb8u2) wird eingerichtet ...
    dh-python (1.20141111-2) wird eingerichtet ...
    python3 (3.4.2-2) wird eingerichtet ...
    running python rtupdate hooks for python3.4...
    running python post-rtupdate hooks for python3.4...
    python3-dev (3.4.2-2) wird eingerichtet ...
    python3-pkg-resources (5.5.1-1) wird eingerichtet ...
    python3-setuptools (5.5.1-1) wird eingerichtet ...
    smarthome@SmartHomeNG:~$ sudo apt-get install python3-pip
    Paketlisten werden gelesen... Fertig
    Abhängigkeitsbaum wird aufgebaut.
    Statusinformationen werden eingelesen.... Fertig
    Die folgenden Pakete wurden automatisch installiert und werden nicht mehr benötigt:
      python-cffi python-colorama python-cryptography python-distlib
      python-html5lib python-ndg-httpsclient python-openssl python-ply
      python-pyasn1 python-pycparser python-urllib3 python-wheel
    Verwenden Sie »apt-get autoremove«, um sie zu entfernen.
    Die folgenden zusätzlichen Pakete werden installiert:
      python3-chardet python3-colorama python3-distlib python3-html5lib
      python3-requests python3-six python3-urllib3 python3-wheel
    Vorgeschlagene Pakete:
      python3-genshi python3-lxml python3-ndg-httpsclient python3-openssl
      python3-pyasn1
    Die folgenden NEUEN Pakete werden installiert:
      python3-chardet python3-colorama python3-distlib python3-html5lib
      python3-pip python3-requests python3-six python3-urllib3 python3-wheel
    0 aktualisiert, 9 neu installiert, 0 zu entfernen und 0 nicht aktualisiert.
    Es müssen noch 0 B von 721 kB an Archiven heruntergeladen werden.
    Nach dieser Operation werden 3.161 kB Plattenplatz zusätzlich benutzt.
    Möchten Sie fortfahren? [J/n] j
    Vormals nicht ausgewähltes Paket python3-chardet wird gewählt.
    (Lese Datenbank ... 44988 Dateien und Verzeichnisse sind derzeit installiert.)
    Vorbereitung zum Entpacken von .../python3-chardet_2.3.0-1_all.deb ...
    Entpacken von python3-chardet (2.3.0-1) ...
    Vormals nicht ausgewähltes Paket python3-colorama wird gewählt.
    Vorbereitung zum Entpacken von .../python3-colorama_0.3.2-1_all.deb ...
    Entpacken von python3-colorama (0.3.2-1) ...
    Vormals nicht ausgewähltes Paket python3-distlib wird gewählt.
    Vorbereitung zum Entpacken von .../python3-distlib_0.1.9-1_all.deb ...
    Entpacken von python3-distlib (0.1.9-1) ...
    Vormals nicht ausgewähltes Paket python3-six wird gewählt.
    Vorbereitung zum Entpacken von .../python3-six_1.8.0-1_all.deb ...
    Entpacken von python3-six (1.8.0-1) ...
    Vormals nicht ausgewähltes Paket python3-html5lib wird gewählt.
    Vorbereitung zum Entpacken von .../python3-html5lib_0.999-3_all.deb ...
    Entpacken von python3-html5lib (0.999-3) ...
    Vormals nicht ausgewähltes Paket python3-urllib3 wird gewählt.
    Vorbereitung zum Entpacken von .../python3-urllib3_1.9.1-3_all.deb ...
    Entpacken von python3-urllib3 (1.9.1-3) ...
    Vormals nicht ausgewähltes Paket python3-requests wird gewählt.
    Vorbereitung zum Entpacken von .../python3-requests_2.4.3-6_all.deb ...
    Entpacken von python3-requests (2.4.3-6) ...
    Vormals nicht ausgewähltes Paket python3-pip wird gewählt.
    Vorbereitung zum Entpacken von .../python3-pip_1.5.6-5_all.deb ...
    Entpacken von python3-pip (1.5.6-5) ...
    Vormals nicht ausgewähltes Paket python3-wheel wird gewählt.
    Vorbereitung zum Entpacken von .../python3-wheel_0.24.0-1_all.deb ...
    Entpacken von python3-wheel (0.24.0-1) ...
    Trigger für man-db (2.7.0.2-5) werden verarbeitet ...
    python3-chardet (2.3.0-1) wird eingerichtet ...
    python3-colorama (0.3.2-1) wird eingerichtet ...
    python3-distlib (0.1.9-1) wird eingerichtet ...
    python3-six (1.8.0-1) wird eingerichtet ...
    python3-html5lib (0.999-3) wird eingerichtet ...
    python3-urllib3 (1.9.1-3) wird eingerichtet ...
    python3-requests (2.4.3-6) wird eingerichtet ...
    python3-pip (1.5.6-5) wird eingerichtet ...
    python3-wheel (0.24.0-1) wird eingerichtet ...
    smarthome@SmartHomeNG:~$ sudo pip install ephem
    sudo: pip: Kommando nicht gefunden
    smarthome@SmartHomeNG:~$ sudo pip3 install ephem
    Traceback (most recent call last):
      File "/usr/bin/pip3", line 9, in <module>
        load_entry_point('pip==1.5.6', 'console_scripts', 'pip3')()
      File "/usr/lib/python3/dist-packages/pkg_resources.py", line 356, in load_entry_point
        return get_distribution(dist).load_entry_point(group, name)
      File "/usr/lib/python3/dist-packages/pkg_resources.py", line 2476, in load_entry_point
        return ep.load()
      File "/usr/lib/python3/dist-packages/pkg_resources.py", line 2190, in load
        ['__name__'])
      File "/usr/lib/python3/dist-packages/pip/__init__.py", line 74, in <module>
        from pip.vcs import git, mercurial, subversion, bazaar  # noqa
      File "/usr/lib/python3/dist-packages/pip/vcs/mercurial.py", line 9, in <module>
        from pip.download import path_to_url
      File "/usr/lib/python3/dist-packages/pip/download.py", line 25, in <module>
        from requests.compat import IncompleteRead
    ImportError: cannot import name 'IncompleteRead'
    Dadurch funktioniert im Backend auch die Systeminfo nicht:
    Code:
    500 Internal Server Error
    The server encountered an unexpected condition which prevented it from fulfilling the request.
    Traceback (most recent call last):
    File "/usr/local/lib/python3.4/dist-packages/cherrypy/_cprequest.py", line 670, in respond response.body = self.handler()
    File "/usr/local/lib/python3.4/dist-packages/cherrypy/lib/encoding.py", line 217, in __call__ self.body = self.oldhandler(*args, **kwargs)
    File "/usr/local/lib/python3.4/dist-packages/cherrypy/_cpdispatch.py", line 61, in __call__ return self.callable(*self.args, **self.kwargs)
    File "/usr/local/smarthome/plugins/backend/__init__.py", line 306, in system_html python_packages = self.getpackages()
    File "/usr/local/smarthome/plugins/backend/__init__.py", line 358, in getpackages import pip
    File "/usr/lib/python3/dist-packages/pip/__init__.py", line 74, in <module> from pip.vcs import git, mercurial, subversion, bazaar # noqa
    File "/usr/lib/python3/dist-packages/pip/vcs/mercurial.py", line 9, in <module> from pip.download import path_to_url
    File "/usr/lib/python3/dist-packages/pip/download.py", line 25, in <module> from requests.compat import IncompleteRead
    ImportError: cannot import name 'IncompleteRead'
    Powered by [URL="http://www.cherrypy.org"]CherryPy 3.5.0[/URL]
    Hab schon die Pakete mit remove deinstalliert, gebootet usw. auch google hilft mir nicht weiter
    cu Yfkt5A
    DALI(ABB DG/S1.1), KODI Odroid, TrueNAS, Zehnder ComfoAir 200 L Luxe
    microk8s-Cluster: HomeAssistant, MusicAssistant, mosquitto, TVHeadend, jellyfin

    #2
    was sagt denn sudo pip3 list

    Kommentar


      #3
      Code:
      sudo pip3 list
      Traceback (most recent call last):
        File "/usr/bin/pip3", line 9, in <module>
          load_entry_point('pip==1.5.6', 'console_scripts', 'pip3')()
        File "/usr/lib/python3/dist-packages/pkg_resources.py", line 356, in load_entry_point
          return get_distribution(dist).load_entry_point(group, name)
        File "/usr/lib/python3/dist-packages/pkg_resources.py", line 2476, in load_entry_point
          return ep.load()
        File "/usr/lib/python3/dist-packages/pkg_resources.py", line 2190, in load
          ['__name__'])
        File "/usr/lib/python3/dist-packages/pip/__init__.py", line 74, in <module>
          from pip.vcs import git, mercurial, subversion, bazaar  # noqa
        File "/usr/lib/python3/dist-packages/pip/vcs/mercurial.py", line 9, in <module>
          from pip.download import path_to_url
        File "/usr/lib/python3/dist-packages/pip/download.py", line 25, in <module>
          from requests.compat import IncompleteRead
      ImportError: cannot import name 'IncompleteRead'
      cu Yfkt5A
      DALI(ABB DG/S1.1), KODI Odroid, TrueNAS, Zehnder ComfoAir 200 L Luxe
      microk8s-Cluster: HomeAssistant, MusicAssistant, mosquitto, TVHeadend, jellyfin

      Kommentar


        #4
        kann bei dem Issue immer nur wieder die Stackoverflow links posten die ich finde: http://stackoverflow.com/questions/3...incompleteread - offenbar ist eine veraltete pip3 version schuld

        Kommentar


          #5
          psilo hat den richtigen Hinweis gegeben, kannst Du hier auch sehen:
          Code:
           
           Vormals nicht ausgewähltes Paket python3-pip wird gewählt. Vorbereitung zum Entpacken von .../python3-pip_[COLOR=#B22222][B]1.5.6[/B][/COLOR]-5_all.deb ... Entpacken von python3-pip (1.5.6-5) ...
          Probier mal sudo easy_install3 -U pip

          Kommentar


            #6
            Das hatte ich auch schon gefunden, aber hab mich nicht getraut mit einem alternativen Installer zu arbeiten. Hatte Angst mir die Paketverwaltung von Debian(apt-get) da irgendwie zu schrotten oder durcheinander zu bringen...

            Aber wenn ihr das schreibt werd ich das mal testen...
            cu Yfkt5A
            DALI(ABB DG/S1.1), KODI Odroid, TrueNAS, Zehnder ComfoAir 200 L Luxe
            microk8s-Cluster: HomeAssistant, MusicAssistant, mosquitto, TVHeadend, jellyfin

            Kommentar


              #7
              Code:
              sudo easy_install3 -U pip
              [sudo] password for smarthome:
              Searching for pip
              Reading https://pypi.python.org/simple/pip/
              Best match: pip 8.1.2
              Downloading https://pypi.python.org/packages/e7/a8/7556133689add8d1a54c0b14aeff0acb03c64707ce100ecd53934da1aa13/pip-8.1.2.tar.gz#md5=87083c0b9867963b29f7aba3613e8f4a
              Processing pip-8.1.2.tar.gz
              Writing /tmp/easy_install-9_ji_ap9/pip-8.1.2/setup.cfg
              Running pip-8.1.2/setup.py -q bdist_egg --dist-dir /tmp/easy_install-9_ji_ap9/pip-8.1.2/egg-dist-tmp-ci2a6lzp
              warning: no previously-included files found matching '.coveragerc'
              warning: no previously-included files found matching '.mailmap'
              warning: no previously-included files found matching '.travis.yml'
              warning: no previously-included files found matching '.landscape.yml'
              warning: no previously-included files found matching 'pip/_vendor/Makefile'
              warning: no previously-included files found matching 'tox.ini'
              warning: no previously-included files found matching 'dev-requirements.txt'
              warning: no previously-included files found matching 'appveyor.yml'
              no previously-included directories found matching '.github'
              no previously-included directories found matching '.travis'
              no previously-included directories found matching 'docs/_build'
              no previously-included directories found matching 'contrib'
              no previously-included directories found matching 'tasks'
              no previously-included directories found matching 'tests'
              Adding pip 8.1.2 to easy-install.pth file
              Installing pip3.4 script to /usr/local/bin
              Installing pip script to /usr/local/bin
              Installing pip3 script to /usr/local/bin
              
              Installed /usr/local/lib/python3.4/dist-packages/pip-8.1.2-py3.4.egg
              Processing dependencies for pip
              Finished processing dependencies for pip
              Scheint trotz der Warnungen funktioniert zu haben...
              zumindest lässt sich die Systeminfo-Seite im Backend jetzt ohne Fehler aufrufen...

              Danke nochmal
              cu Yfkt5A
              DALI(ABB DG/S1.1), KODI Odroid, TrueNAS, Zehnder ComfoAir 200 L Luxe
              microk8s-Cluster: HomeAssistant, MusicAssistant, mosquitto, TVHeadend, jellyfin

              Kommentar


                #8
                Ich habe das mal in die Komplettanleitung aufgenommen...

                Kommentar

                Lädt...
                X