Issue with Migration to Kite Connect 3.0

naz
@sujith
I am trying "pip install kiteconnect --upgrade --pre" to migrate pykiteconnect client to version 3.0 but am getting below error.



Also, kiteconnect installed version is showing 3.6.2
Can you please guide me on the same.
  • naz
    naz edited April 2018
    @zartimus
    I am using anaconda (64 bit) python 3.6.3 on Windows for sometime and cPython has been running smoothly (since I have been using numpy, pandas etc.) so I am guessing Microsoft Visual C+ 14 compiler version shouldn't be an issue. The break happens only when we try to migrate to Kite version 3 (previous version of kite is also running smoothly).

    In any case, I downloaded "https://www.visualstudio.com/downloads/#build-tools-for-visual-studio-2017" and reinstalled it. But it is giving the same error again.

    I also tried downloading zip file directly (https://github.com/zerodhatech/pykiteconnect/archive/kite3.zip) and doing "python setup.py install". Attaching the logfile while doing this (pip show kiteconnect still shows version 3.6.2).
  • zartimus
    zartimus edited April 2018
    @naz
    so I am guessing Microsoft Visual C+ 14 compiler version shouldn't be an issue
    Nope. Kiteconnect v3 uses twisted behind the scenes for websocket. Issue is twisted wheels are not distributed properly and that brings the microsoft visual C++ compiler into picture. So, for every os platform, python version twisted needs to be compiled. As a workaround we compiled them beforehand and the kiteconnect setup.py picks it from our wheels repository.

    Now logfile says
    Requirement already satisfied: Twisted==17.9.0 from https://raw.githubusercontent.com/zerodhatech/python-wheels/master/Twisted-17.9.0-cp36-cp36m-win_amd64.whl in c:\programdata\anaconda3\lib\site-packages (17.9.0)
    So the hardest part is done
    Processing kiteconnect-3.7.0b10-py3.6.egg
    Removing c:\programdata\anaconda3\lib\site-packages\kiteconnect-3.7.0b10-py3.6.egg
    Copying kiteconnect-3.7.0b10-py3.6.egg to c:\programdata\anaconda3\lib\site-packages
    Which is exactly we need.

    Lastly,
    Finished processing dependencies for kiteconnect==3.7.0b10
    So is it working or not? No error inside your logfile

    Can you remove the existing kiteconnect from sitepackages?
    pip uninstall kiteconnect and do it all over again
  • naz
    naz edited April 2018
    Correct. But it didn't upgrade the current kiteconnect 3.6.2 to kiteconnect 3.7 when i did a "pip show kiteconnect" (I am assuming that it should show version as 3.7.x post correct migration/upgradataion - correct me here).

    Following is what apparently solved my issue (in case useful for others):
    - check if following command is going through (based on the thread mentioned above):
    pip install https://raw.githubusercontent.com/zerodhatech/python-wheels/master/Twisted-17.9.0-cp36-cp36m-win_amd64.whl

    - If it shows an error "pdfminer-six requires pycryptodome", do "pip install pycryptodom" and then the above pip install Twisted-17.9.0-cp36-cp36m-win_amd64.whl should go through successfully.

    - After that do a "pip install kiteconnect --upgrade --pre" again. Now the Visual C++14 compiler error should disappear. Doing a "pip install kiteconnect --upgrade --pre" again should upgrade the current kiteconnect 3.6.2 version to 3.7.0b10

    @zartimus Thanks much for the help and quick reverts.
This discussion has been closed.