)]}'
{"oslo_service/loopingcall.py":[{"author":{"_account_id":9796,"name":"ChangBo Guo","email":"glongwave@gmail.com","username":"gcb"},"change_message_id":"43b656f54d48ee85b64dd97fa311b755813d405c","unresolved":false,"context_lines":[{"line_number":181,"context_line":"                            {\u0027func_name\u0027: func_name, \u0027delay\u0027: delay})"},{"line_number":182,"context_line":"            elapsed_time \u003d time.time() - start_time"},{"line_number":183,"context_line":"            if timeout \u003e 0 and elapsed_time \u003e timeout:"},{"line_number":184,"context_line":"                raise LoopingCallTimeOut("},{"line_number":185,"context_line":"                    _(\u0027Looping call timed out after %.02f seconds\u0027)"},{"line_number":186,"context_line":"                    % elapsed_time)"},{"line_number":187,"context_line":"            return -delay if delay \u003c 0 else 0"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a6eadb0_eb80274c","line":184,"range":{"start_line":184,"start_character":1,"end_line":184,"end_character":41},"updated":"2016-12-19 05:42:58.000000000","message":"API caller usually raises loopingcall.LoopingCallDone to notify that work is done, and in Line 147, we catch the exception and continue to run.\n\n\nSo I suggest we don\u0027t change FixedIntervalLoopingCall\u0027s behavior, instead just create a new Class like  FixedIntervalTimeOutLoopingCall, and provide argument to pass timeout handler in new class, and catch LoopingCallTimeOut in Line 149 and execute the handler and finish the greenthread( self.done.send(XXX))","commit_id":"5cccb8feb250dc3f94b23602c54f2d7b92e3ab87"},{"author":{"_account_id":9796,"name":"ChangBo Guo","email":"glongwave@gmail.com","username":"gcb"},"change_message_id":"e6b09c357c05f989c4882420c86c891c132bed21","unresolved":false,"context_lines":[{"line_number":146,"context_line":"                greenthread.sleep(idle)"},{"line_number":147,"context_line":"        except LoopingCallDone as e:"},{"line_number":148,"context_line":"            self.done.send(e.retvalue)"},{"line_number":149,"context_line":"        except LoopingCallTimeOut as e:"},{"line_number":150,"context_line":"            LOG.warning(_LW(\u0027Looping call timed out.\u0027))"},{"line_number":151,"context_line":"            self.done.send_exception(e)"},{"line_number":152,"context_line":"        except Exception:"},{"line_number":153,"context_line":"            exc_info \u003d sys.exc_info()"},{"line_number":154,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"1a6eadb0_35fec86b","line":151,"range":{"start_line":149,"start_character":0,"end_line":151,"end_character":39},"updated":"2016-12-20 03:29:51.000000000","message":"Thought again, we need send sys.exc_info to preserve the entire original stack trace. See https://github.com/eventlet/eventlet/blob/master/eventlet/event.py#L190\n\nThen we don\u0027t need L149 ~L151, need more input from others","commit_id":"ad355c1420afae11ae0878520931f6cf749cb672"},{"author":{"_account_id":13248,"name":"Wenzhi Yu","email":"wenzhi_yu@163.com","username":"yuywz"},"change_message_id":"e4d2b8db5c54d1d5b616e3bf1b1f7b984f8263eb","unresolved":false,"context_lines":[{"line_number":146,"context_line":"                greenthread.sleep(idle)"},{"line_number":147,"context_line":"        except LoopingCallDone as e:"},{"line_number":148,"context_line":"            self.done.send(e.retvalue)"},{"line_number":149,"context_line":"        except LoopingCallTimeOut as e:"},{"line_number":150,"context_line":"            LOG.warning(_LW(\u0027Looping call timed out.\u0027))"},{"line_number":151,"context_line":"            self.done.send_exception(e)"},{"line_number":152,"context_line":"        except Exception:"},{"line_number":153,"context_line":"            exc_info \u003d sys.exc_info()"},{"line_number":154,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"ba5201f7_d33a46e7","line":151,"range":{"start_line":149,"start_character":0,"end_line":151,"end_character":39},"in_reply_to":"1a6eadb0_35fec86b","updated":"2016-12-29 06:23:52.000000000","message":"Done","commit_id":"ad355c1420afae11ae0878520931f6cf749cb672"}]}
