subscribe_user_data_event stream disconnecting very frequently


I’m having trouble getting a clean connection to my user data stream.
The stream works, but I keep getting disconnected very frequently. (please see picture down below)

This happens towards the testnet and towards production.
Other websocket streams(like for price data) work perfectly.

I’m getting the listen key like this;
def getListenKey():
return request_client.start_user_data_stream()

then starting the stream like this;
sub_client.subscribe_user_data_event(getListenKey(), callback, error)

Can anyone point me in the right direction how I can try to fix this?
Thank you!

I’ve added
receive_limit_ms=3600000 and
to it, but that also didn’t work

Sometimes also when I start the stream, no updates will come through at all, even though I am definitely placing orders on the testnet. then i stop my code and rerun it, and after a couple tries it will work

Is this for testnet or PROD?

Both, but I notice that adding this actually worked, (the default is very low)