Mattermost, Inc.

[SOLVED] Sending one message per second on a hook gives me a ConnectionResetError

I need to send one message per second via an incoming web hook. It works for a while but after a few seconds I get a ConnectionResetError (in Python). I checked the Rate limiting settings because my first thought was that Mattermost was preventing this kind of behaviour by kicking the bot out. I have

Enable rate limiting = false
Maximum queries per second = 10
Maximum Burst Size = 3000000
Vary rate limit by remote address = false

Still, I keep getting those connection resets and I don’t know why.

Should I keep the connection open between the python program and Mattermost?

I was using urllib and switched to the requests module. I don’t get connection reset anymore so it looks like it was an issue on python’s side. :wink: