)]}'
{"mistral/event_engine/default_event_engine.py":[{"author":{"_account_id":11583,"name":"Arnaud Morin","email":"arnaud.morin@gmail.com","username":"arnaudmorin"},"change_message_id":"1525b4032bab450046a227cdaad21974c6362649","unresolved":true,"context_lines":[{"line_number":138,"context_line":"    # Seconds _loop() waits on the queue before re-checking _stopped. Small"},{"line_number":139,"context_line":"    # enough that shutdown stays prompt, large enough that an idle engine"},{"line_number":140,"context_line":"    # costs nothing."},{"line_number":141,"context_line":"    _QUEUE_POLL_TIMEOUT \u003d 1"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"    def __init__(self):"},{"line_number":144,"context_line":"        self.engine_client \u003d rpc.get_engine_client()"}],"source_content_type":"text/x-python","patch_set":2,"id":"58c20394_241214da","line":141,"updated":"2026-10-15 22:20:41.000000000","message":"I confirm the issue but I dont think this is the correct fix.\nRather than relying on a timeout, we should rather use a sentinel value to exit:\n\n  def stop(self):\n      self._stopped \u003d True\n      self.event_queue.put(None)     # wake the thread with a \"quit\" note\n      self._thread.join()\n\n  def _loop(self):\n      while True:\n          event \u003d self.event_queue.get()   # sleep until something arrives, no timeout\n          if event is None:                # the quit note\n              break\n          ...process event...","commit_id":"719e5c45f9046ec666641f96c25468bd90bb8b5b"}],"mistral/tests/unit/services/test_event_engine.py":[{"author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"tag":"autogenerated:zuul:check","change_message_id":"9410e3631272875ddfb4bebcfbe3f458b05dc83f","unresolved":false,"context_lines":[{"line_number":206,"context_line":""},{"line_number":207,"context_line":"        # Waiting on the queue wakes at most once per timeout. Polling would"},{"line_number":208,"context_line":"        # be several orders of magnitude above that."},{"line_number":209,"context_line":"        max_expected \u003d idle / evt_eng.DefaultEventEngine._QUEUE_POLL_TIMEOUT + 2"},{"line_number":210,"context_line":""},{"line_number":211,"context_line":"        self.assertLessEqual("},{"line_number":212,"context_line":"            len(gets),"}],"source_content_type":"text/x-python","patch_set":1,"id":"11145014_307ff3fe","line":209,"updated":"2026-10-05 06:05:00.000000000","message":"pep8: E501 line too long (80 \u003e 79 characters)","commit_id":"4dec600c4471cd184ee4ccf22228a529a37a2f67"},{"author":{"_account_id":11583,"name":"Arnaud Morin","email":"arnaud.morin@gmail.com","username":"arnaudmorin"},"change_message_id":"605522982fbea1c8c547b555d1008af18785ef26","unresolved":true,"context_lines":[{"line_number":184,"context_line":"        time.sleep(0.5)"},{"line_number":185,"context_line":"        e_engine.stop()"},{"line_number":186,"context_line":""},{"line_number":187,"context_line":"        # At most one get() waiting while idle and one returning the stop"},{"line_number":188,"context_line":"        # sentinel. A polling loop makes thousands."},{"line_number":189,"context_line":"        self.assertLessEqual(get.call_count, 2)"},{"line_number":190,"context_line":"        self.assertFalse(e_engine._thread.is_alive())"}],"source_content_type":"text/x-python","patch_set":3,"id":"dde7fc0f_016393e7","line":187,"updated":"2026-10-16 10:16:05.000000000","message":"I think this is even only one, not two. But that works","commit_id":"2a9247f01cd639e242c683c14850b8a8e286ca32"}]}
