ImportError: No module named _winreg, Installing pypiwin32==219 on MacOS X

I am trying to install pypiwin32==219 in my virtual environment from a requirements.txt file.

requirements.txt

pypiwin32==219 

I have setup a virtualenv denv in which I am working.

(denv) Nehas-MacBook-Pro:dash_pdf neha$ pip install -r requirements.txt 

I got this traceback error:

Complete output from command python setup.py egg_info: Traceback (most recent call last): File "<string>", line 1, in <module> File "/private/var/folders/_y/g09fpxn13xq7z6ptmq3095dm0000gn/T/pip-install-7zp59n5n/pypiwin32/setup.py", line 121 print "Building pywin32", pywin32_version ^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print("Building pywin32", pywin32_version)? 

which really is a python version issue so I switched to the command:

(denv) Nehas-MacBook-Pro:dash_pdf neha$ pip2 install -r requirements.txt 

upon which I get this traceback error:

Using cached Complete output from command python setup.py egg_info: Traceback (most recent call last): File "<string>", line 1, in <module> File "/private/var/folders/_y/g09fpxn13xq7z6ptmq3095dm0000gn/T/pip-install-KEpN56/pypiwin32/setup.py", line 83, in <module> import _winreg ImportError: No module named _winreg 

I googled some and I found that _winreg required Windows. No way I can get pypiwin32==219 to work on MacOS?

1 Answer

The entire pypiwin32 module requires Windows. It is, after all, the Win32 API bindings for Python – none of it would be usable on anything that isn't Windows.

1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

You Might Also Like