Patrick ONeill Patrick ONeill - 1 year ago 134
Perl Question

error when installing python packages with PIP

Whenever I try to install a python package I get the following error.

C:\Python27>pip install pyaardvark

C:\strawberry\perl\bin/pip: Perl lib version (5.22.0) doesn't match executable '
C:\strawberry\perl\bin\perl.exe' version (5.16.3) at C:/strawberry/perl/lib/Conf line 62.
Compilation failed in require at C:/strawberry/perl/lib/ line 8.
BEGIN failed--compilation aborted at C:/strawberry/perl/lib/ line 8.
Compilation failed in require at C:/strawberry/perl/lib/File/ line 148.
BEGIN failed--compilation aborted at C:/strawberry/perl/lib/File/ line 14
Compilation failed in require at C:/strawberry/perl/vendor/lib/ line 6.
BEGIN failed--compilation aborted at C:/strawberry/perl/vendor/lib/ line 6
Compilation failed in require at C:\strawberry\perl\bin/pip line 5.
BEGIN failed--compilation aborted at C:\strawberry\perl\bin/pip line 5.

Does anyone have any ideas??

Answer Source

In your PATH environment variable, your Perl directories likely preceed the Python ones, so when you call pip, it fires the pip binary located in your Strawberry Perl instance.

Try calling pip with its full path, eg: c:\python27\bin\pip. I don't have access to a Windows box at the moment, so that may not be the actual path and you'll have to find the actual location.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download