No subject
Sun Apr 26 06:47:01 MDT 2009
class NetstringReceiver(protocol.Protocol):
def doLength(self):
...
raise NetstringParseError, "netstring too long"
...
def dataReceived(self, data):
...
try:
...
self.doLength()
...
except NetstringParseError:
self.transport.loseConnection()
self.brokenPeer = 1
The error message "netstring too long" is shadowed by the except
block. I'd like to see it in my log files.
Would it make sense to emit logging messaged for those errors, or is
there any particular reason why they are silenced?
Cheers,
Carlos
More information about the Twisted-Python
mailing list