2017-09-21 1 views
-2

Ich installierte Anaconda3 in meinem Computer und erstellt eine virtualenv namens Python27 mit Python-Version 2.7, ich möchte mehrere Pakete in meinem virtualenv installieren, aber Conda installieren oder pip installieren funktioniert für einige Pakete und nicht für andere, zum Beispiel, war ich nicht in der Lage csv zu installieren, wird ein Paket durch Komma getrennte Wert Dokumente zu verwalten, ist dies die Ausgabe I Conda installieren lassen mit:kann nicht installieren einige Pakete mit Conda installieren oder pip installieren

$ conda install csv 
Fetching package metadata ......... 

PackageNotFoundError: Packages missing in current channels: 

    - csv 

We have searched for the packages in the following channels: 

    - https://repo.continuum.io/pkgs/free/linux-64 
    - https://repo.continuum.io/pkgs/free/noarch 
    - https://repo.continuum.io/pkgs/r/linux-64 
    - https://repo.continuum.io/pkgs/r/noarch 
    - https://repo.continuum.io/pkgs/pro/linux-64 
    - https://repo.continuum.io/pkgs/pro/noarch 

und mit pip installieren:

$ pip install csv 
Collecting csv 
Could not find a version that satisfies the requirement csv (from versions:) 
No matching distribution found for csv 

Wie installiere ich die Paket csv in meinem virtualenv oder einem anderen Paket konnte ich nicht auf diese Weise installieren?

Vielen Dank im Voraus.

Antwort

0

Es ist ein Standardbibliotheksmodul: csv. Es sollte ohne Installation verfügbar sein.

Nur um sicherzustellen, dass ich es mit einer sauberen Umgebung getestet habe.

$ conda create -n test python # new environment without any additional packages 
$ activate test     # go to that environment 
$ python      # start the python interpreter 
>>> import csv     # importing it works! 
2

Sie können csv nicht installieren, da es bereits in Ihrer Python-Installation enthalten ist.

Gehen Sie einfach

import csv