'no close frame received or sent' issue

It is throwing message ’ no close frame received’ after some feeds. How to keep feed capturing open?

2 Likes

same issue for me i’m using paid subscription ,again after 1 or 2 min connection breaks. i not paid for this
Dhan developers kindly let me know any fix for this or my subscription is useless

{‘type’: ‘Ticker Data’, ‘exchange_segment’: 1, ‘security_id’: 5097, ‘LTP’: ‘292.95’, ‘LTT’: ‘13:56:24’}
{‘type’: ‘Ticker Data’, ‘exchange_segment’: 1, ‘security_id’: 5097, ‘LTP’: ‘292.95’, ‘LTT’: ‘13:56:26’}
{‘type’: ‘Ticker Data’, ‘exchange_segment’: 1, ‘security_id’: 5097, ‘LTP’: ‘292.95’, ‘LTT’: ‘13:56:28’}
{‘type’: ‘Ticker Data’, ‘exchange_segment’: 1, ‘security_id’: 5097, ‘LTP’: ‘292.95’, ‘LTT’: ‘13:56:30’}
{‘type’: ‘Ticker Data’, ‘exchange_segment’: 1, ‘security_id’: 5097, ‘LTP’: ‘292.95’, ‘LTT’: ‘13:56:31’}
An error occurred: no close frame received or sent
Connection closed!

4 Likes

Same here …Again and again its disconnecting …

hi Hardik …any reason , Multiple times i need to reconnect …because of below error
Error in DHAN Live Feed no close frame received or sent

1 Like

@Hardik tagging hardik here to bring the issue to his notice.
The issue is happening completely random. it will be working fine and suddenly the code would stop with the mentioned error and we have to trigger it again.

Pls dont rely on 1 datafeed provide, have backup sockets and even if those fail fallback to Quotes/ API calls

1 Like

Hello @avinashpaul01

Thank you for tagging. We are looking into this random occurrence and how it can be avoided.

1 Like

@Hardik This is really a serious issue. I opted for Dhan as my platform for algo trading as it say madefortrade and coded by strategy which is based on Marketfeed and while initially I thought everything will work but in trial I noticed that feed keeps disconnecting after sometime. It is a serious issue to be looked in to and resolved.

1 Like

Hello @rahul108

Would like to connect and resolve this here. This shouldn’t be happening now if the async function is running and while loop is maintained. Let me know if we can connect sometime today or tomorrow to get this resolved. You can DM me directly.

I am facing the same issue. This is really unacceptable

I can see that this issue has been reported in other parts of the forum, weeks back. Shame it hasnt been resolved yet!

Hello @pritam_dhar

Welcome to MadeForTrade community!

Can you confirm if you are using the code on GitHub hands on? Or is there any modification to while loop?

I have tried the native base code as well as calling a custom function instead of the print (response) in your code

For now I am recursively calling the same function in exception block to automatically reconnect on the said exception. This is not ideal