3

Please note that i am running all installs in elevated(Administrator) mode. I am trying to install a a package called gearman using the command pip install gearman. Below is the output.

Collecting gearman

Using cached gearman-2.0.2.tar.gz

Complete output from command python setup.py egg_info:
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\Users\ANURAG~1\AppData\Local\Temp\pip-build-yk442wl_\gearman\setup.py", line 5, in <module>
    from gearman import __version__ as version
  File "C:\Users\ANURAG~1\AppData\Local\Temp\pip-build-yk442wl_\gearman\gearman\__init__.py", line 7, in <module>
    from gearman.admin_client import GearmanAdminClient
  File "C:\Users\ANURAG~1\AppData\Local\Temp\pip-build-yk442wl_\gearman\gearman\admin_client.py", line 4, in <module>
    from gearman import util
  File "C:\Users\ANURAG~1\AppData\Local\Temp\pip-build-yk442wl_\gearman\gearman\util.py", line 62
    except select_lib.error, exc:
                           ^
SyntaxError: invalid syntax

----------------------------------------

Command "python setup.py egg_info" failed with error code 1 in C:\Users\ANURAG~1\AppData\Local\Temp\pip-build-yk442wl_\gearman\

i followed this stackoverflow page and am trying the first answer.I am stuck at "easy_install -U setuptools"

This command throws error: [WinError 5] Access is denied: 'c:\program files\python\Scripts\easy_install.exe'

The following is the stack trace.

Searching for setuptools

Reading https://pypi.python.org/simple/setuptools/

Best match: setuptools 34.3.3

Processing setuptools-34.3.3-py3.5.egg

setuptools 34.3.3 is already the active version in easy-install.pth

Installing easy_install-script.py script to c:\program files\python\Scripts

Installing easy_install.exe script to c:\program files\python\Scripts

error: [WinError 5] Access is denied: 'c:\program files\python\Scripts\easy_install.exe'

I searched for the error "The WinError 5 Access is denied" and the blogs are saying that you have to run in administrator mode + to try with anti-virus disabling. I have tried both and the result is the same. Note that all the commands are being run in administrator mode. Kindly help. Thanks in advance. I am using python 3.5 as my interpreter and running on windows.

Community
  • 1
  • 1
Anurag Narra
  • 95
  • 1
  • 9
  • `except select_lib.error, exc:` is Python 2 syntax. You need to see if there's a port of this gearman module, or install Python 2 to use it. – Eryk Sun Apr 05 '17 at 16:06
  • You don't need to install setuptools in Python 3.5; it's included with pip. Just keep your pip up to date via `python -m pip install --upgrade pip`. – Eryk Sun Apr 05 '17 at 16:08
  • 2
    The access denied error you're getting in this case has nothing to do with permissions. Windows doesn't allow deleting a file that's memory-mapped, such as a running executable or loaded DLL (it can be renamed to a new name and directory; just not unlinked), so of course trying to use easy_install.exe to replace itself will fail. – Eryk Sun Apr 05 '17 at 16:10
  • Thank you for the help...there seems to be no gearman module for 3.5.. i am moving on to hadoop and spark. – Anurag Narra Apr 08 '17 at 06:12
  • eryksun's solution helped me. In this answer you can see more details how to do it. – lyubeto Oct 02 '17 at 11:56

0 Answers0