[Tutor] Installing modules with easy_install
Ray Jones
crawlzone at gmail.com
Tue Aug 28 22:48:16 CEST 2012
On 08/28/2012 01:35 PM, Emile van Sebille wrote:
> On 8/28/2012 1:17 PM Ray Jones said...
>> On 08/28/2012 01:11 PM, eryksun wrote:
>>> On Tue, Aug 28, 2012 at 4:00 PM, Ray Jones <crawlzone at gmail.com> wrote:
>>>> Oops. No, I see that /usr/local/lib/python2.7/dist-packages is
>>>> included
>>>> in the sys.path. Now what?
>>> Good, but does sys.path contain
>>> /usr/local/lib/python2.7/dist-packages/pytz-2012d-py2.7.egg?
>> More info:
>>
>> /usr/lib/python2.7/dist-packages does not contain a easy-install.pth
>> file.
>>
>
> You installed this with easy_install, so the version of python therein
> referenced is the same one that now should have access to it.
>
> Try : which easy_install
>
> then cat the result. The first line points to the executable python
> that installed pytz. On my local system this looks like:
>
>
> head -1 `which easy_install`
> #! /usr/bin/python
>
> copy and paste in the result, then import pytz from there and paste in
> the results if it doesn't work.
#! /usr/bin/python
I think you come late to the party, but jump in - there's lots of room!
We have solved the pytz problem by quarantining the pytz*.egg and
installing python-tz from the Debian system. But while pytz now works,
it does not address the problem of easy-install-ed modules not being
recognized by python (btw, in perusing the
/usr/local/bin/.../dist-packages I also found a shodan module (whatever
that is) that python does not recognize - and I don't find shodan in the
Debian packages).
Ray
More information about the Tutor
mailing list