matplotlib
をpip
経由でインストールします。しかし、私は循環的な問題にぶつかり、ある時点で私は立ち往生した。matplotlibをインストールするために依存関係を解決するには?
Traceback (most recent call last):
File "/usr/bin/pip", line 5, in <module>
from pkg_resources import load_entry_point
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 3080, in <module>
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 3066, in _call_aside
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 3093, in _initialize_master_working_set
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 651, in _build_master
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 952, in require
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 839, in resolve
pkg_resources.DistributionNotFound: The 'pip==1.5.4' distribution was not found and is required by the application
私はeasy_install
でこの問題を解決しようとしたが、それは次のエラーメッセージを生成:ターミナル内pip
が生成する実行
Traceback (most recent call last):
File "/usr/bin/easy_install", line 5, in <module>
from pkg_resources import load_entry_point
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 3080, in <module>
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 3066, in _call_aside
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 3093, in _initialize_master_working_set
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 653, in _build_master
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 666, in _build_from_requirements
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 839, in resolve
pkg_resources.DistributionNotFound: The 'setuptools==3.3' distribution was not found and is required by the application
はsudo apt-get install python-setuptools
を実行すると、私はすでに最新バージョンを持っていることを言います。
OSはUbuntu 14.04
です。私はこの問題を解決するためにさまざまなアプローチを試みましたが、おそらくさらに害を及ぼすことになりました。私はすべてのことを思い出していないし、どのように私がこの段階で終わったのか、残念ながらさらなる情報を与えることはできない。
私の目的は、matplotlib
を最後にインストールし、すべての私のpython
関連ライブラリの安定した状態を持つことです。どんな解決策も効果がありますので、問題を解決するために必要なものすべてを再インストールしても構いません。 sudo apt-get install python-matplotlib
しかし、matplotlib
はまだpython
から発見されない
Reading package lists... Done
Building dependency tree
Reading state information... Done
python-matplotlib is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 5 not upgraded.
を生産するのに対しsudo apt-get build-dep python-matplotlib
を実行
UPDATE
は
Reading package lists... Done
Building dependency tree
Reading state information... Done
Picking 'matplotlib' as source package instead of 'python-matplotlib'
E: Unable to find a source package for matplotlib
を生成します。
あなたは 'virtualenv'での作業を考えましたか? –
私の人生が楽になり、回避策に似ているかどうかはわかりません。私はそれがどのように動作しているのかは分かりませんが、私が作業しているプロジェクトは主に 'C'プロジェクトであり、いくつかの面白いものに' python'を使用しています。 –
'virtualenv'は一般的な修正プログラムとしても使用できます。必要なライブラリをすべてインストールしなくても、別のマシンでプログラムを実行しなくても、ソフトウェアを配布する必要がある場合は便利です。セットアップと使用はかなり簡単です:https://virtualenv.pypa.io/en/stable/userguide.html –