ed
79c25a329f
fix(layout): pre-run install of bundled INI before HelloImgui's load_user_pref
...
The previous followup fix (e9654518 , then 2afb0126 ) only applied the bundled
INI to HelloImgui's runtime state via `imgui.load_ini_settings_from_memory`,
called from the `post_init` callback. That callback fires AFTER HelloImgui
has already:
1. loaded user prefs from disk
2. loaded imgui settings from disk (via imgui.load_ini_settings_from_disk)
3. set up the dockspace tree
By the time post_init fires, HelloImgui has already discarded the empty
on-disk INI's data and built its dock state. The load_ini_settings_from_memory
apply in post_init ended up being SILENTLY DISCARDED for [Docking][Data]
entries with orphaned DockSpace IDs.
Empirical evidence: manual launch test (sloppy.py without --enable-test-hooks)
after 2afb0126 produced a saved manualslop_layout.ini of 3072 bytes with
2 DockNode entries, but those DockNodes were created at RUNTIME, not
loaded from the bundled INI's literal IDs. The imgui core loader rejected
the literal IDs from the bundled INI because the runtime IDs didn't match.
Fix: add `_install_default_layout_pre_run_result` to App.run entry, called
BEFORE `_run_immapp_result`. It writes the bundled INI to cwd if cwd's INI
is missing/empty/small, so when HelloImgui's load_user_pref / load_ini_settings_from_disk
runs, it reads my bundled INI as the initial state. The literal DockSpace
ID 0xAFC85805 (= runtime-generated MainDockSpace 2949142533) matches,
the DockNode IDs 0x00000001/0x00000002 match (because HelloImgui restores
dock IDs from INI), and per-window DockId references apply to the matching
DockNodes.
The post_init live-session apply (imgui.load_ini_settings_from_memory) is
now mostly redundant for first-launch: HelloImgui reads the bundled INI on
its initial load. But it's still there for any edge case where HelloImgui's
load_ini_settings_from_disk reads an INI after the pre-run write somehow
fails, AND it covers the "user manually wiped cwd INI mid-session" case.
Test changes:
- _assert_live_session_apply renamed to _assert_install_applied -- the
primary path is now pre-run, and the test accepts either
"[GUI] pre-run installed default layout:" or
"[GUI] installed default layout: ... (and applied to live session)"
- Updated test 1 and 2 to use the new helper name
Empirical verification (re-run of 18s manual launch):
- Before launch: cwd INI absent
- During launch: [GUI] pre-run installed default layout: ...layouts/default.ini -> ...manualslop_layout.ini
- During launch: [GUI] visible-by-default windows: AI Settings, Diagnostics,
Discussion Hub, Files & Media, Log Management, Operations Hub, Project
Settings, Response, Theme
- After force-kill: cwd/manualslop_layout.ini is 3072 bytes containing
[Docking][Data] with DockSpace ID=0xAFC85805 + DockNode ID=0x00000001
(CentralNode=1, SizeRef=481,1172) + DockNode ID=0x00000002
(SizeRef=1197,1172) + 8 [Window][...] entries with DockId=0x00000001,N or
DockId=0x00000002,N + 0 stale window names
- 17/17 tests pass
2026-06-29 19:52:42 -04:00
..
2026-06-29 14:20:51 -04:00
2026-05-10 15:38:16 -04:00
2026-06-24 10:03:48 -04:00
2026-03-02 22:56:32 -05:00
2026-06-25 11:18:03 -04:00
2026-06-08 00:46:12 -04:00
2026-06-08 00:33:21 -04:00
2026-06-29 14:20:51 -04:00
2026-06-27 16:31:45 -04:00
2026-05-04 21:52:39 -04:00
2026-05-14 22:23:48 -04:00
2026-06-08 00:47:21 -04:00
2026-05-13 22:35:52 -04:00
2026-03-05 17:13:59 -05:00
2026-03-05 14:04:17 -05:00
2026-05-06 13:48:47 -04:00
2026-06-18 12:09:00 -04:00
2026-06-17 00:38:29 -04:00
2026-06-17 00:38:29 -04:00
2026-06-25 11:18:03 -04:00
2026-05-13 22:35:52 -04:00
2026-06-06 15:11:13 -04:00
2026-06-17 00:38:29 -04:00
2026-06-26 07:07:12 -04:00
2026-06-26 07:07:12 -04:00
2026-06-26 07:07:12 -04:00
2026-06-26 07:07:12 -04:00
2026-05-09 15:00:35 -04:00
2026-03-11 23:14:09 -04:00
2026-06-17 00:38:29 -04:00
2026-06-08 20:46:41 -04:00
2026-06-08 17:49:34 -04:00
2026-06-08 15:19:30 -04:00
2026-05-12 19:06:54 -04:00
2026-06-07 19:54:17 -04:00
2026-06-22 01:00:06 -04:00
2026-06-08 20:46:41 -04:00
2026-06-07 10:20:17 -04:00
2026-06-08 10:13:07 -04:00
2026-06-21 10:38:17 -04:00
2026-03-11 23:04:42 -04:00
2026-06-08 23:45:25 -04:00
2026-06-19 14:25:53 -04:00
2026-06-06 16:34:46 -04:00
2026-06-25 11:18:03 -04:00
2026-06-27 11:54:09 -04:00
2026-06-19 16:24:01 -04:00
2026-06-08 23:45:25 -04:00
2026-06-08 20:46:41 -04:00
2026-06-02 21:34:56 -04:00
2026-06-26 23:42:14 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 23:18:27 -04:00
2026-05-10 15:14:54 -04:00
2026-05-20 07:51:58 -04:00
2026-05-13 22:35:52 -04:00
2026-06-07 10:23:45 -04:00
2026-06-07 10:54:51 -04:00
2026-06-17 18:53:25 -04:00
2026-06-18 09:37:28 -04:00
2026-06-20 11:59:20 -04:00
2026-06-26 09:24:10 -04:00
2026-06-07 15:24:57 -04:00
2026-06-06 14:22:18 -04:00
2026-06-20 01:47:23 -04:00
2026-06-21 12:43:22 -04:00
2026-06-26 23:18:27 -04:00
2026-05-08 22:01:15 -04:00
2026-06-24 11:08:07 -04:00
2026-06-20 20:01:25 -04:00
2026-06-08 00:41:20 -04:00
2026-05-06 13:48:47 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-08 01:14:12 -04:00
2026-06-08 00:27:04 -04:00
2026-06-09 17:01:14 -04:00
2026-06-09 16:40:18 -04:00
2026-06-03 00:52:08 -04:00
2026-05-13 22:35:52 -04:00
2026-03-04 10:01:55 -05:00
2026-06-25 09:29:24 -04:00
2026-06-22 00:42:44 -04:00
2026-06-25 09:29:24 -04:00
2026-06-25 09:29:24 -04:00
2026-06-25 09:29:24 -04:00
2026-06-25 09:29:24 -04:00
2026-06-27 10:17:51 -04:00
2026-06-26 06:54:59 -04:00
2026-06-26 06:54:59 -04:00
2026-06-25 14:47:18 -04:00
2026-06-03 14:25:59 -04:00
2026-06-03 14:53:05 -04:00
2026-06-26 13:34:03 -04:00
2026-05-13 22:35:52 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-09 18:42:53 -04:00
2026-06-26 13:34:03 -04:00
2026-05-16 11:22:41 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-18 12:09:00 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-03-22 12:59:10 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-03-05 16:37:30 -05:00
2026-06-27 10:17:51 -04:00
2026-06-25 14:47:18 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-05-13 22:35:52 -04:00
2026-06-17 00:38:29 -04:00
2026-06-29 19:52:42 -04:00
2026-06-26 06:59:30 -04:00
2026-06-06 18:30:44 -04:00
2026-06-02 01:42:41 -04:00
2026-06-25 14:47:18 -04:00
2026-06-07 19:54:17 -04:00
2026-05-09 15:00:35 -04:00
2026-06-15 18:21:58 -04:00
2026-06-03 08:33:10 -04:00
2026-05-09 12:35:58 -04:00
2026-06-26 13:34:03 -04:00
2026-06-24 13:48:33 -04:00
2026-06-07 21:21:38 -04:00
2026-06-26 13:34:03 -04:00
2026-06-19 14:25:53 -04:00
2026-05-16 03:00:20 -04:00
2026-06-26 23:18:27 -04:00
2026-06-16 19:06:09 -04:00
2026-06-07 10:10:53 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 23:18:27 -04:00
2026-05-20 07:51:58 -04:00
2026-06-26 05:07:35 -04:00
2026-03-06 12:48:02 -05:00
2026-05-16 03:00:20 -04:00
2026-06-17 00:38:29 -04:00
2026-06-17 00:38:29 -04:00
2026-06-17 00:38:29 -04:00
2026-05-13 22:35:52 -04:00
2026-06-20 20:01:25 -04:00
2026-06-07 21:21:38 -04:00
2026-05-10 15:38:16 -04:00
2026-06-20 17:54:48 -04:00
2026-06-26 22:38:46 -04:00
2026-06-26 07:07:12 -04:00
2026-05-13 22:35:52 -04:00
2026-05-13 22:35:52 -04:00
2026-06-17 00:38:29 -04:00
2026-06-27 12:02:20 -04:00
2026-06-09 15:37:47 -04:00
2026-06-06 17:16:53 -04:00
2026-06-26 22:38:46 -04:00
2026-06-07 14:43:36 -04:00
2026-03-13 12:05:49 -04:00
2026-06-25 18:20:45 -04:00
2026-05-13 22:35:52 -04:00
2026-06-03 11:27:04 -04:00
2026-06-07 19:54:17 -04:00
2026-06-03 11:27:04 -04:00
2026-06-26 23:18:27 -04:00
2026-06-19 12:36:21 -04:00
2026-05-13 22:35:52 -04:00
2026-06-19 09:40:01 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 14:06:03 -04:00
2026-05-13 22:35:52 -04:00
2026-05-16 03:00:20 -04:00
2026-06-03 11:27:04 -04:00
2026-06-07 19:54:17 -04:00
2026-06-02 17:30:46 -04:00
2026-06-02 02:20:07 -04:00
2026-05-13 22:35:52 -04:00
2026-06-02 17:30:46 -04:00
2026-06-06 21:29:03 -04:00
2026-05-16 01:21:27 -04:00
2026-06-08 15:19:30 -04:00
2026-06-27 10:17:51 -04:00
2026-05-13 22:35:52 -04:00
2026-06-26 13:34:03 -04:00
2026-06-02 01:27:32 -04:00
2026-05-16 03:00:20 -04:00
2026-06-25 14:47:18 -04:00
2026-05-05 17:50:55 -04:00
2026-06-07 19:54:17 -04:00
2026-06-26 23:42:14 -04:00
2026-06-17 22:42:10 -04:00
2026-05-12 19:02:30 -04:00
2026-06-08 17:51:39 -04:00
2026-06-07 19:54:17 -04:00
2026-06-07 01:34:48 -04:00
2026-06-15 09:41:39 -04:00
2026-06-09 15:37:47 -04:00
2026-06-17 00:38:29 -04:00
2026-06-15 11:04:46 -04:00
2026-06-09 15:42:00 -04:00
2026-06-18 14:26:12 -04:00
2026-06-03 17:37:44 -04:00
2026-06-24 13:48:47 -04:00
2026-06-15 13:52:38 -04:00
2026-06-26 07:07:12 -04:00
2026-06-03 13:47:08 -04:00
2026-06-15 18:27:40 -04:00
2026-06-07 21:21:38 -04:00
2026-03-06 12:48:02 -05:00
2026-03-07 12:43:29 -05:00
2026-06-22 01:00:00 -04:00
2026-05-09 15:00:35 -04:00
2026-06-21 23:06:54 -04:00
2026-06-06 18:01:39 -04:00
2026-06-26 13:34:03 -04:00
2026-06-03 21:48:12 -04:00
2026-06-06 16:58:32 -04:00
2026-06-04 23:13:33 -04:00
2026-06-03 21:14:16 -04:00
2026-06-03 11:08:58 -04:00
2026-06-03 21:33:47 -04:00
2026-06-03 10:59:57 -04:00
2026-05-06 13:48:47 -04:00
2026-06-12 18:07:16 -04:00
2026-06-26 23:18:27 -04:00
2026-03-05 17:13:59 -05:00
2026-06-26 10:19:39 -04:00
2026-06-20 19:48:00 -04:00
2026-06-25 09:29:24 -04:00
2026-06-26 14:06:03 -04:00
2026-06-26 07:07:12 -04:00
2026-06-25 11:18:03 -04:00
2026-05-09 15:00:35 -04:00
2026-05-16 14:45:06 -04:00
2026-05-13 22:35:52 -04:00
2026-05-13 22:35:52 -04:00
2026-06-07 19:54:17 -04:00
2026-05-16 14:45:06 -04:00
2026-06-26 13:34:03 -04:00
2026-05-16 03:00:20 -04:00
2026-05-16 03:00:20 -04:00
2026-03-05 16:37:30 -05:00
2026-03-07 20:32:59 -05:00
2026-06-07 17:57:36 -04:00
2026-06-26 13:34:03 -04:00
2026-06-10 09:16:46 -04:00
2026-06-25 14:47:18 -04:00
2026-03-02 13:26:20 -05:00
2026-06-26 20:04:00 -04:00
2026-06-26 22:38:46 -04:00
2026-06-18 14:40:04 -04:00
2026-06-26 07:07:12 -04:00
2026-06-22 00:59:42 -04:00
2026-06-26 13:34:03 -04:00
2026-06-19 12:36:21 -04:00
2026-06-17 00:30:48 -04:00
2026-06-17 22:31:35 -04:00
2026-06-26 13:34:03 -04:00
2026-05-13 22:35:52 -04:00
2026-06-26 05:07:35 -04:00
2026-06-25 14:47:18 -04:00
2026-06-19 12:36:21 -04:00
2026-06-26 13:34:03 -04:00
2026-05-06 14:59:34 -04:00
2026-06-26 13:34:03 -04:00
2026-05-06 14:30:22 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-05-10 15:46:53 -04:00
2026-05-04 18:49:18 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-05-09 15:00:35 -04:00
2026-06-26 13:34:03 -04:00
2026-06-03 15:18:18 -04:00
2026-06-06 01:12:29 -04:00
2026-06-07 19:54:17 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 14:06:03 -04:00
2026-05-06 13:48:47 -04:00
2026-06-26 13:34:03 -04:00
2026-06-19 09:40:01 -04:00
2026-06-26 23:18:27 -04:00
2026-05-16 15:59:40 -04:00
2026-06-26 20:04:00 -04:00
2026-06-11 16:38:09 -04:00
2026-06-25 14:47:18 -04:00
2026-06-25 12:03:02 -04:00
2026-06-22 00:59:50 -04:00
2026-06-11 16:38:09 -04:00
2026-06-20 08:25:27 -04:00
2026-06-08 00:47:03 -04:00
2026-06-15 18:05:45 -04:00
2026-06-25 14:47:18 -04:00
2026-06-26 22:38:46 -04:00
2026-06-12 20:14:01 -04:00
2026-06-27 21:52:18 -04:00
2026-05-16 15:59:40 -04:00
2026-06-26 23:18:27 -04:00
2026-06-28 09:24:06 -04:00
2026-06-27 21:52:18 -04:00
2026-06-26 13:34:03 -04:00
2026-06-27 22:39:19 -04:00
2026-06-09 10:37:14 -04:00
2026-06-29 16:48:05 -04:00
2026-06-10 15:14:35 -04:00
2026-06-12 16:29:22 -04:00
2026-06-26 13:34:03 -04:00
2026-06-09 16:14:40 -04:00
2026-05-16 15:59:40 -04:00
2026-05-16 14:45:06 -04:00
2026-06-25 14:47:18 -04:00
2026-06-25 11:18:03 -04:00
2026-03-12 19:08:51 -04:00
2026-03-06 16:43:11 -05:00
2026-05-16 14:45:06 -04:00
2026-05-13 22:35:52 -04:00
2026-05-13 22:35:52 -04:00
2026-05-13 22:35:52 -04:00
2026-05-13 22:35:52 -04:00
2026-05-13 22:35:52 -04:00
2026-03-07 11:54:11 -05:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-06 13:57:26 -04:00
2026-05-15 17:17:05 -04:00
2026-05-04 04:52:40 -04:00
2026-06-26 05:01:15 -04:00
2026-03-07 15:20:39 -05:00
2026-06-17 00:38:29 -04:00
2026-05-09 15:00:35 -04:00
2026-05-09 15:00:35 -04:00
2026-06-09 16:25:44 -04:00
2026-03-19 19:53:09 -04:00
2026-06-07 19:54:17 -04:00
2026-05-13 22:35:52 -04:00
2026-05-16 14:45:06 -04:00
2026-03-09 23:16:02 -04:00
2026-06-19 14:25:53 -04:00
2026-06-06 16:55:20 -04:00
2026-06-04 22:31:22 -04:00
2026-06-17 14:20:17 -04:00
2026-06-17 10:26:32 -04:00
2026-03-09 01:13:23 -04:00
2026-06-04 23:16:21 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-15 14:26:32 -04:00
2026-06-26 13:34:03 -04:00
2026-06-24 23:20:16 -04:00
2026-06-16 19:13:30 -04:00
2026-06-16 20:25:44 -04:00
2026-06-17 14:50:01 -04:00
2026-06-19 07:41:15 -04:00
2026-06-16 22:26:04 -04:00
2026-06-17 00:38:29 -04:00
2026-06-06 16:09:16 -04:00
2026-06-26 13:34:03 -04:00
2026-05-10 10:13:56 -04:00
2026-06-17 00:38:29 -04:00
2026-06-25 13:11:44 -04:00
2026-06-25 11:18:03 -04:00
2026-06-26 13:34:03 -04:00
2026-06-25 14:47:18 -04:00
2026-03-11 20:30:09 -04:00
2026-05-09 15:00:35 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 23:18:27 -04:00
2026-06-09 16:14:40 -04:00
2026-06-26 13:34:03 -04:00
2026-06-26 13:34:03 -04:00
2026-05-13 22:35:52 -04:00
2026-06-20 19:48:00 -04:00
2026-06-20 19:48:00 -04:00
2026-06-26 04:27:56 -04:00
2026-05-04 05:18:04 -04:00
2026-06-25 14:47:18 -04:00
2026-06-26 23:18:27 -04:00
2026-05-09 16:55:45 -04:00
2026-03-09 23:25:06 -04:00
2026-03-07 21:40:40 -05:00
2026-06-26 07:07:12 -04:00
2026-06-26 07:10:06 -04:00
2026-06-21 15:32:46 -04:00
2026-06-21 15:34:18 -04:00
2026-06-21 16:33:44 -04:00
2026-06-21 15:35:41 -04:00
2026-06-21 15:39:22 -04:00
2026-06-26 23:18:27 -04:00
2026-06-10 15:13:25 -04:00
2026-05-16 03:00:20 -04:00
2026-06-10 15:45:44 -04:00
2026-06-27 22:39:19 -04:00
2026-03-04 09:46:02 -05:00
2026-06-27 11:54:09 -04:00
2026-06-07 16:02:30 -04:00
2026-06-21 22:39:14 -04:00
2026-06-22 01:00:06 -04:00
2026-03-04 10:01:55 -05:00
2026-06-26 13:34:03 -04:00
2026-06-09 20:45:24 -04:00
2026-06-26 13:34:03 -04:00
2026-05-13 22:35:52 -04:00
2026-06-10 15:14:35 -04:00