Tamir Duberstein
f6519a355a
Preserve TUI event ordering during active-thread draining ( #39991 )
...
## Why
Draining every queued active-thread event in one foreground pass can overrun the
frame budget. Buffered thread events can also race ahead of queued replay and
startup app events, causing the TUI to switch views before the corresponding
history and operations have been applied.
## What changed
- Bound active-thread draining to one target frame interval and leave remaining
notifications queued for a later frame.
- Prioritize queued app events over active-thread events so replay state is
applied before buffered closures or other thread notifications.
- Block startup input only for pending requests, rather than ordinary queued
notifications whose draining yielded at the frame deadline.
- Leave selected side-thread closure handling to the foreground event loop.
## Testing
Added tests covering deadline-limited notification draining and foreground
handling of a selected side thread closing.
GitOrigin-RevId: 41080d3df13ca308eec1ea0fbb0ba067a4640c4c
2026-08-21 18:43:37 +00:00
..
2026-08-21 18:43:37 +00:00
2026-08-17 22:31:13 +00:00
2026-08-21 05:35:35 +00:00
2026-08-21 06:19:23 +00:00
2026-08-17 00:32:09 +00:00
2026-08-14 20:23:49 +00:00
2026-08-17 16:46:26 +00:00
2026-08-17 16:34:21 +00:00
2026-08-13 04:08:23 +00:00
2026-08-21 06:19:23 +00:00
2026-08-21 06:19:23 +00:00
2026-07-29 14:01:31 +00:00
2026-08-17 21:06:34 +00:00
2026-08-17 19:59:22 +00:00
2026-08-17 16:58:24 +00:00
2026-08-20 05:49:49 +00:00
2026-08-17 19:59:22 +00:00
2026-08-14 16:33:28 +00:00
2026-08-21 06:19:23 +00:00
2026-08-19 04:46:58 +00:00
2026-08-17 19:49:47 +00:00
2026-08-14 20:23:49 +00:00
2026-08-20 06:39:20 +00:00
2026-08-17 21:49:30 +00:00
2026-08-13 00:30:08 +00:00
2026-07-21 14:25:18 +00:00
2026-07-15 01:07:29 +00:00
2026-08-21 06:19:23 +00:00
2026-07-22 23:45:45 +00:00
2026-06-15 19:25:54 -07:00
2026-08-21 06:08:26 +00:00
2026-08-21 06:19:23 +00:00
2026-06-17 19:52:43 +02:00
2026-07-23 23:13:59 +00:00
2026-08-04 16:53:33 +00:00
2026-08-21 06:19:23 +00:00
2026-08-18 00:31:51 +00:00
2026-08-20 06:57:00 +00:00
2026-08-17 21:06:34 +00:00
2026-08-17 22:58:25 +00:00
2026-08-14 20:23:49 +00:00
2026-08-20 17:36:22 +00:00
2026-08-17 16:50:47 +00:00
2026-08-16 03:14:17 +00:00
2026-08-16 03:14:17 +00:00
2026-08-04 16:53:33 +00:00
2026-06-05 08:34:34 -07:00
2026-07-29 03:50:00 +00:00
2026-06-12 17:14:27 -07:00
2026-08-13 04:08:23 +00:00
2026-08-13 04:08:23 +00:00
2026-08-20 06:39:20 +00:00
2026-08-01 17:43:03 +00:00
2026-08-21 06:19:23 +00:00
2026-08-21 06:19:23 +00:00
2026-08-20 07:25:40 +00:00
2026-07-29 14:01:31 +00:00
2026-07-29 14:01:31 +00:00
2026-07-29 14:01:31 +00:00
2026-06-24 03:10:20 +00:00
2026-08-11 19:16:15 +00:00
2026-06-26 19:27:31 +00:00
2026-06-26 19:27:31 +00:00
2026-07-29 14:01:31 +00:00
2026-07-29 14:01:31 +00:00
2026-07-19 16:50:54 +00:00
2026-06-08 17:02:36 -07:00
2026-07-18 18:00:51 +00:00
2026-07-12 19:18:37 +00:00
2026-08-14 20:23:49 +00:00
2026-08-17 17:10:16 +00:00
2026-08-17 22:31:13 +00:00
2026-08-05 20:44:03 +00:00
2026-08-17 22:44:37 +00:00
2026-08-14 20:30:30 +00:00
2026-08-17 19:59:22 +00:00
2026-08-18 23:05:52 +00:00
2026-08-17 17:14:46 +00:00
2026-08-18 23:05:52 +00:00
2026-07-29 13:53:15 +00:00
2026-08-19 02:45:45 +00:00
2026-08-19 02:45:45 +00:00
2026-08-20 12:17:44 +00:00
2026-08-17 22:44:37 +00:00
2026-08-19 02:45:45 +00:00
2026-08-14 20:59:34 +00:00
2026-08-20 07:25:40 +00:00
2026-08-20 07:25:40 +00:00
2026-06-18 15:06:23 -07:00
2026-08-17 17:10:16 +00:00
2026-07-20 15:44:37 +00:00
2026-08-17 22:50:25 +00:00
2026-08-16 05:59:34 +00:00
2026-08-18 00:31:51 +00:00
2026-06-10 11:24:29 -07:00
2026-08-15 05:53:54 +00:00
2026-08-21 06:08:26 +00:00
2026-08-14 20:38:52 +00:00
2026-08-14 20:38:52 +00:00
2026-08-01 17:43:03 +00:00
2026-07-29 13:53:15 +00:00
2026-08-17 20:06:41 +00:00
2026-07-27 17:59:06 +00:00
2026-08-14 20:23:49 +00:00
2026-06-05 17:23:45 -07:00
2026-08-13 00:30:08 +00:00
2026-06-10 17:55:49 -07:00
2026-07-29 14:01:31 +00:00
2026-08-13 04:08:23 +00:00
2026-08-20 07:58:28 +00:00
2026-08-04 19:05:45 +00:00
2026-08-15 17:30:13 +00:00
2026-08-20 06:39:20 +00:00
2026-07-06 16:33:13 -04:00
2026-08-20 07:25:40 +00:00
2026-08-20 07:25:40 +00:00
2026-07-08 12:17:58 -04:00
2026-08-14 20:23:49 +00:00
2026-06-12 09:26:08 -07:00
2026-06-12 09:26:08 -07:00
2026-07-28 19:58:25 +00:00
2026-07-29 14:01:31 +00:00
2026-06-11 09:23:08 -07:00
2026-06-11 18:16:39 -07:00
2026-06-22 04:25:07 -07:00
2026-06-22 04:25:07 -07:00
2026-07-29 14:01:31 +00:00