error while using kite historical ?

tanmay
I am using 200 stocks for historical purpose. I have used time.sleep(1) after each historical record and have used while True . Once the code takes all 200 stock data, it will sleep for 100 seconds and then again start taking data. But I am getting this error

DataException: Unknown Content-Type (text/html) with response: (b"

504 Gateway Time-out

\nThe server didn't respond in time.\n\n")

Please help.
  • rakeshr
    @tanmay
    Can you re-check if you are sending the correct request parameters?
  • tanmay
    tanmay edited April 2020
    records = kite.historical_data(token, current_day,current_day,'15minute')

    here is the parameter which i am using. I am only using today's data for 200 stocks
    Also I am able to get data for one round of complete 200 stocks. But after it sleeps when it again iterates , it gives me this error
Sign In or Register to comment.