)]}'
{"gerritbot/bot.py":[{"author":{"_account_id":5263,"name":"Jeremy Stanley","display_name":"fungi","email":"fungi@yuggoth.org","username":"fungi","status":"missing, presumed fed"},"change_message_id":"ba90f02e7cdc2e2c9bc4134c6014fb48cf2eb6cb","unresolved":false,"context_lines":[{"line_number":136,"context_line":"            # bytes long, just ignore it, sometimes users forget to separate"},{"line_number":137,"context_line":"            # the commit subject from the body with a blank line (a future"},{"line_number":138,"context_line":"            # alternative could be to truncate to some safe length and retry)"},{"line_number":139,"context_line":"            pass"},{"line_number":140,"context_line":"        except Exception:"},{"line_number":141,"context_line":"            # If an exception was raised on sending, suspect that there may be"},{"line_number":142,"context_line":"            # trouble with the connection and try to reconnect, explicitly"}],"source_content_type":"text/x-python","patch_set":1,"id":"63ef362c_5be43162","line":139,"updated":"2021-03-19 22:03:06.000000000","message":"Should we also log something here? I guess that might be good just to leave a breadcrumb when someone goes log spelunking to find out why some change wasn\u0027t announced.","commit_id":"bea87c170aa1797c5c75005beeddfa1226d99552"},{"author":{"_account_id":5263,"name":"Jeremy Stanley","display_name":"fungi","email":"fungi@yuggoth.org","username":"fungi","status":"missing, presumed fed"},"change_message_id":"8ae0ce2c494f005bea9d403a75040a2c27b1885b","unresolved":false,"context_lines":[{"line_number":129,"context_line":"        self.all_channels[channel_name].stamp()"},{"line_number":130,"context_line":"        try:"},{"line_number":131,"context_line":"            self.connection.privmsg(channel_name, msg)"},{"line_number":132,"context_line":"            time.sleep(0.5)"},{"line_number":133,"context_line":"        except Exception:"},{"line_number":134,"context_line":"            # If an exception was raised on sending, suspect that there may be"},{"line_number":135,"context_line":"            # trouble with the connection and try to reconnect, explicitly"}],"source_content_type":"text/x-python","patch_set":2,"id":"d5ebdda5_1b30fa33","side":"PARENT","line":132,"updated":"2021-03-19 22:22:13.000000000","message":"I considered that, but truncation in this case means we leave off the end of the change URL, which isn\u0027t especially helpful. Also when a commit message is that malformed, it\u0027s more likely noise not worth announcing anyway. If someone wants to work out a way to front-load length checking of the commit subject string and calculate a safe limit before assembling the message passed into this method, then that would be cool as a follow-up change. The point of this change is simply to avoid unnecessary reconnects when such a change comes across the event stream.","commit_id":"03c21d836993338894c91551d10d86dbd4541114"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"1a9f14666bb7942a73f907d64a8d4f365121ca98","unresolved":true,"context_lines":[{"line_number":129,"context_line":"            time.sleep(0.5)"},{"line_number":130,"context_line":"        self.all_channels[channel_name].stamp()"},{"line_number":131,"context_line":"        try:"},{"line_number":132,"context_line":"            self.connection.privmsg(channel_name, msg)"},{"line_number":133,"context_line":"            time.sleep(0.5)"},{"line_number":134,"context_line":"        except irc.client.MessageTooLong:"},{"line_number":135,"context_line":"            # If the server chokes because we tried to send something \u003e512"}],"source_content_type":"text/x-python","patch_set":2,"id":"c9a4a561_fd086b08","line":132,"updated":"2021-03-19 22:13:36.000000000","message":"What about also truncating messages that are too long? The RFC appears to say a message can be a maximum of 512 characters. Though the command and CR/LF are part of the message.\n\nI would think 400-450 characters as a limit on what is sent what be plenty.\n\n\n[0] https://tools.ietf.org/html/rfc1459#section-2.3","commit_id":"43dcd9d297bcbfff1c3ff219723276bcc407a014"},{"author":{"_account_id":4146,"name":"Clark Boylan","email":"cboylan@sapwetik.org","username":"cboylan"},"change_message_id":"6b477c8735cc248a30fec3a3cef7dc2b8274ff6f","unresolved":true,"context_lines":[{"line_number":129,"context_line":"            time.sleep(0.5)"},{"line_number":130,"context_line":"        self.all_channels[channel_name].stamp()"},{"line_number":131,"context_line":"        try:"},{"line_number":132,"context_line":"            self.connection.privmsg(channel_name, msg)"},{"line_number":133,"context_line":"            time.sleep(0.5)"},{"line_number":134,"context_line":"        except irc.client.MessageTooLong:"},{"line_number":135,"context_line":"            # If the server chokes because we tried to send something \u003e512"}],"source_content_type":"text/x-python","patch_set":2,"id":"e9c35090_d2004c4f","line":132,"in_reply_to":"c9a4a561_fd086b08","updated":"2021-03-19 22:18:38.000000000","message":"Ya, we can trim it down to a reasonable length and then if we still end up over (due to utf8 binary encoding or long channel names or long gerrit Full Names, etc) we can skip then. But we can add that in a followup. Another options woudl be to split the message on whitespace and send it in multiple chunks.","commit_id":"43dcd9d297bcbfff1c3ff219723276bcc407a014"}]}
