0

I want to install whois python module in windows. i tried to install whois module using command

python setup.py install

downlaoded from

https://pypi.python.org/pypi/pythonwhois

but when i try to import whois module it gives error

>>> import whois

Traceback (most recent call last):
  File "<pyshell#0>", line 1, in <module>
    import whois
ImportError: No module named whois

thanx in advance

Jayesh Jodhawat
  • 69
  • 1
  • 17

2 Answers2

2

I would suggest that you should install pip first. http://docs.python-guide.org/en/latest/starting/install/win/ OR How do I install pip on Windows?

After that go to command prompt and simply type:
pip install whois

This should do it.

Update: Alternate way to install whois?
Step 1: After installing pyhton, add the following to the PATH in the Environmental Variables.

C:\Python27\;C:\Python27\Scripts\

Step 2: Download ez_setup.py. Run it and it will install Setuptools.

Step 3: Go to command line/powershell and type:

easy_install whois

Step 4: You are done! Go to python and import whois

Community
  • 1
  • 1
user3798749
  • 136
  • 8
  • Be aware that that installs the `whois` module (which is not maintained, and seems incomplete), rather than the `pythonwhois` module. Disclaimer: I'm the author of `pythonwhois`. – Sven Slootweg Oct 27 '14 at 02:06
1

try using pip - http://pip.readthedocs.org/en/latest/installing.html, download the file, run the script and then you can do like this - http://www.pythonforbeginners.com/dns/using-pywhois, pip install python-whois.