**CODE: **
from fyers_api.Websocket import ws
symbol= [‘NSE:SBIN-EQ’,‘NSE:ONGC-EQ’]
def custom_message(msg):
print (f"Custom:{msg}")
ws.websocket_data = custom_message
fyersSocket = ws.FyersSocket(access_token=access_token,run_background=False,log_path=‘home/Documents/Quant/Fyers_login’)
fyersSocket.subscribe(symbol=symbol,data_type=data_type)
Error:
FileNotFoundError: [Errno 2] No such file or directory: ‘C:\Users\KIIT\home\Documents\Quant\Fyers_login\fyers_socket.log’
