Error—Here the condition match in Britannia stock; the order should be placed, also the Error in Vwap Indicator
Logging into zerodha
You have already loggged in for today
reading existing file all_instrument 2025-08-23.csv
you are connected to zerodha Tarun Sharma
name RSI EMA Supertrend Buy Conditions Sell Conditions Traded Watchlist
ACC
[!] VWAP volume series is not datetime ordered. Results may not be as expected.
[!] VWAP price series is not datetime ordered. Results may not be as expected.
<string>:1: UserWarning: Converting to PeriodArray/Index representation will drop timezone information.
('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None))
Traceback (most recent call last):
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 789, in urlopen
response = self._make_request(
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 536, in _make_request
response = conn.getresponse()
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connection.py", line 507, in getresponse
httplib_response = super().getresponse()
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 1322, in getresponse
response.begin()
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 303, in begin
version, status, reason = self._read_status()
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 264, in _read_status
line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\socket.py", line 669, in readinto
return self._sock.recv_into(b)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\ssl.py", line 1241, in recv_into
return self.read(nbytes, buffer)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\ssl.py", line 1099, in read
return self._sslobj.read(len, buffer)
ConnectionResetError: [WinError 10054] An existing connection was forcibly closed by the remote host
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\requests\adapters.py", line 667, in send
resp = conn.urlopen(
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 843, in urlopen
retries = retries.increment(
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\util\retry.py", line 474, in increment
raise reraise(type(error), error, _stacktrace)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\util\util.py", line 38, in reraise
raise value.with_traceback(tb)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 789, in urlopen
response = self._make_request(
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connectionpool.py", line 536, in _make_request
response = conn.getresponse()
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\urllib3\connection.py", line 507, in getresponse
httplib_response = super().getresponse()
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 1322, in getresponse
response.begin()
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 303, in begin
version, status, reason = self._read_status()
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\http\client.py", line 264, in _read_status
line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\socket.py", line 669, in readinto
return self._sock.recv_into(b)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\ssl.py", line 1241, in recv_into
return self.read(nbytes, buffer)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\ssl.py", line 1099, in read
return self._sslobj.read(len, buffer)
urllib3.exceptions.ProtocolError: ('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\Zerodha_Tradehull\Zerodha_Tradehull.py", line 206, in get_short_length_hist_data
instrument_token = self.kite.ltp(exchange+":"+name)[exchange+":"+name]['instrument_token']
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\kiteconnect\connect.py", line 611, in ltp
return self._get("market.quote.ltp", params={"i": ins})
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\kiteconnect\connect.py", line 861, in _get
return self._request(route, "GET", url_args=url_args, params=params, is_json=is_json)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\kiteconnect\connect.py", line 916, in _request
raise e
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\kiteconnect\connect.py", line 904, in _request
r = self.reqsession.request(method,
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\requests\sessions.py", line 589, in request
resp = self.send(prep, **send_kwargs)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\requests\sessions.py", line 703, in send
r = adapter.send(request, **kwargs)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\requests\adapters.py", line 682, in send
raise ConnectionError(err, request=request)
requests.exceptions.ConnectionError: ('Connection aborted.', ConnectionResetError(10054, 'An existing connection was forcibly closed by the remote host', None, 10054, None))
Traceback (most recent call last):
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\runpy.py", line 192, in _run_module_as_main
return _run_code(code, main_globals, None,
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "c:\Users\HP\.vscode\extensions\ms-python.debugpy-2025.10.0-win32-x64\bundled\libs\debugpy\launcher/../..\debugpy\__main__.py", line 71, in <module>
cli.main()
File "c:\Users\HP\.vscode\extensions\ms-python.debugpy-2025.10.0-win32-x64\bundled\libs\debugpy\launcher/../..\debugpy/..\debugpy\server\cli.py", line 501, in main
run()
File "c:\Users\HP\.vscode\extensions\ms-python.debugpy-2025.10.0-win32-x64\bundled\libs\debugpy\launcher/../..\debugpy/..\debugpy\server\cli.py", line 351, in run_file
runpy.run_path(target, run_name="__main__")
File "c:\Users\HP\.vscode\extensions\ms-python.debugpy-2025.10.0-win32-x64\bundled\libs\debugpy\_vendored\pydevd\_pydevd_bundle\pydevd_runpy.py", line 310, in run_path
return _run_module_code(code, init_globals, run_name, pkg_name=pkg_name, script_name=fname)
File "c:\Users\HP\.vscode\extensions\ms-python.debugpy-2025.10.0-win32-x64\bundled\libs\debugpy\_vendored\pydevd\_pydevd_bundle\pydevd_runpy.py", line 127, in _run_module_code
_run_code(code, mod_globals, init_globals, mod_name, mod_spec, pkg_name, script_name)
File "c:\Users\HP\.vscode\extensions\ms-python.debugpy-2025.10.0-win32-x64\bundled\libs\debugpy\_vendored\pydevd\_pydevd_bundle\pydevd_runpy.py", line 118, in _run_code
exec(code, run_globals)
File "d:\Trudehull_Algo Traning\Practice File\Test_file_23-08-2025-new.py", line 34, in <module>
chart['RSI'] = talib.RSI(chart['close'], timeperiod=14)
TypeError: 'NoneType' object is not subscriptable
PS D:\Trudehull_Algo Traning\Practice File> ^C
PS D:\Trudehull_Algo Traning\Practice File>
PS D:\Trudehull_Algo Traning\Practice File> d:; cd 'd:\Trudehull_Algo Traning\Practice File'; & 'c:\Users\HP\AppData\Local\Programs\Python\Python38\python.exe' 'c:\Users\HP\.vscode\extensions\ms-python.debugpy-2025.10.0-win32-x64\bundled\libs\debugpy\launcher' '58163' '--' 'd:\Trudehull_Algo Traning\Practice File\Test_file_23-08-2025-new.py'
Logging into zerodha
You have already loggged in for today
reading existing file all_instrument 2025-08-23.csv
you are connected to zerodha Tarun Sharma
reading existing file all_instrument 2025-08-23.csv
reading existing file all_instrument 2025-08-23.csv
reading existing file all_instrument 2025-08-23.csv
you are connected to zerodha Tarun Sharma
name RSI EMA Supertrend Buy Conditions Sell Conditions Traded Watchlist
ACC
ACC 47.1 1821.4 1 False True False False False False True True []
ASIANPAINT
ASIANPAINT 40.3 2505.0 -1 False False True False False True False True []
BAJAJ-AUTO
BAJAJ-AUTO 59.8 8680.7 -1 False False True True False True False False []
BRITANNIA
BRITANNIA 67.4 5551.3 1 True True True True False False False False []
Traceback (most recent call last):
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\Zerodha_Tradehull\Zerodha_Tradehull.py", line 1260, in place_order
order_id = self.kite.place_order(variety=variety, exchange=exchange, tradingsymbol=tradingsymbol, transaction_type=transaction_type, quantity=quantity, product=product, order_type=order_type, price=price, validity=validity, disclosed_quantity=disclosed_quantity, trigger_price=trigger_price, validity_ttl= validity_ttl,iceberg_legs = iceberg_legs, iceberg_quantity=iceberg_quantity, auction_number= auction_number, tag=tag)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\kiteconnect\connect.py", line 361, in place_order
return self._post("order.place",
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\kiteconnect\connect.py", line 865, in _post
return self._request(route, "POST", url_args=url_args, params=params, is_json=is_json, query_params=query_params)
File "c:\Users\HP\AppData\Local\Programs\Python\Python38\lib\site-packages\kiteconnect\connect.py", line 937, in _request
raise exp(data["message"], code=r.status_code)
kiteconnect.exceptions.InputException: Invalid `api_key` or `access_token`.