Skip to content

Stack overflow in WindowRateLimiter.Throttle after reconnect #199

@airforce270

Description

@airforce270

Hi,

I've run into this error a couple times - after reconnecting, when trying to make a connection, there is a stack overflow in github.com/gempir/go-twitch-irc/v4.(*WindowRateLimiter).Throttle(0x400030b290, 0x14) as it calls itself recursively over and over.

Logs and stack trace: https://gist.github.com/airforce270/93d4fba434b3fec390af2fbd855c6376

I've tried looking at the client code but am pretty unfamiliar with how it works.

If it's helpful, here's the way I'm using the client, simplified:

client.Connect()
client.Join(/* channels */)

// bot running...

// twitch requests reconnect

client.Depart(/* channels */)
client.Disconnect()

client.Connect()
client.Join(/* channels */)

/* after a couple seconds, stack overflow */

Links to my usage:

Happy to provide any other needed info.

Any help would be appreciated, thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions