Closed aldum closed 8 years ago
Thanks but no thanks. I'm not sure I fully understand the implications of suppressing the exception and stopping iteration. For example, I imagine you could DoS the server by sending two undecodeable lines in each packet.
See the readme on the recommendations for how to handle encoding problems. The library provides clear interfaces on how to handle robustly any encoding situations.
As many times as users have encountered this situation, I would be inclined to change the default behavior from raising exceptions to replacing undecodeable characters, a la
irc.client.ServerConnection.buffer_class.errors = 'replace'
But one thing I don't want to do is alter the codebase in a way that silently suppresses errors without giving clients any control over it.
You're right, it's not a very well-engineered solution. Thanks for your time.
This should catch a specific exception right now it'll eat every exception