ModuleNotFoundError: No module named 'kiteconnect' -only on cmd

Hi All,
I am facing a problem with cmd and kiteconnect, I have installed Python 3.6 using python-3.6.8-amd64.exe
I also have installed, wheel and kiteconnect properly for the best of my understanding.
I have run this python programs in cmd before and they were successful, I can run them in "sublime text" also.
The problem is while these programs are still working in "sublime text" but not in cmd, and keep on throwing "ModuleNotFoundError: No module named 'kiteconnect'"

my basic program is like this:
from kiteconnect import KiteConnect
print (dir(KiteConnect))
I run it like this:
Traceback (most recent call last):
File "", line 2, in
from kiteconnect import KiteConnect
ModuleNotFoundError: No module named 'kiteconnect'

the "kiteconnect" is installed properly:
C:\Users\kush\Desktop\Python>pip show kiteconnect
Name: kiteconnect
Version: 3.8.2
Summary: The official Python client for the Kite Connect trading API
Author: Zerodha Technology Pvt ltd. (India)
Author-email: [email protected]
License: MIT
Location: c:\users\kush\appdata\local\programs\python\python36\lib\site-packages
Requires: requests, six, pyOpenSSL, enum34, python-dateutil, autobahn, pywin32

Python is also proper:
Python 3.6.8 (tags/v3.6.8:3c6b436a57, Dec 24 2018, 00:16:47) [MSC v.1916 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.

Please help.
  • rakeshr
    It seems kiteconnect package is not in a directory where it can be accessed via CMD or you have multiple python version installed in your system.Maybe you can go through this thread.
  • sourabhs
    Hi All,
    Rakesh it seems that problem is related to location only. It is solved now, procedure:
    1. pip show kiteconnect
    ---> It shows the location of kiteconnect:
    2. I went to that location, and ran python program from that location with absolute address.
    ---> worked (meh)
This discussion has been closed.