← Commit history

pup-bridge-debug: the Win11 tile-bake law, the category-appId swap pattern, the pin tradeoff, and the title-race retry lesson

John Lauer ·50b47469d0 ·3mo ago ·parent 750fe28
1 file changed +27
dev-skills/pup-bridge-debug/SKILL.md+27
@@ -202,6 +202,33 @@ the authed profile collapse into TABS of one window, the "(session: <id>)" title active tab, and every per-window operation (stamp, overlay, flash, jump list) silently fails for the background sessions - the original reason the login icon would not repaint after a view toggle. +## Live taskbar tile changes: the category-appId swap (v1.9.27-28, AD-measured, do NOT re-derive)++Win11 BAKES a taskbar button's tile when the button is created and never re-reads it. AD measured+every candidate mechanism (WIN11_TASKBAR_ICON.md Part 7): WM_SETICON, GCLP_HICON, ITaskbarList+DeleteTab+AddTab, SHChangeNotify(ASSOCCHANGED), SWP_FRAMECHANGED, RedrawWindow, the TaskbarCreated+broadcast - ALL leave the tile unchanged. The ONLY live repaint is making the shell create a NEW+button, which stamping a DIFFERENT AppUserModelID does (~1s, no flicker).++pup therefore bakes the category INTO the per-session appId: `Adom.Pup.<sid>.<category>`. A+category flip = register the new appId (registry-only, BEFORE the stamp so the fresh button+resolves its icon immediately) -> desktop_set_window_identity with the new appId -> unregister the+old appId. The jump list attaches to the AUMID, so it must re-attach after a swap (pup resets+_wikiJumplistView). Session teardown captures _curAppId BEFORE sessions.delete or the cleanup+misses and leaks the registration.++TRADEOFF (Windows constraint): a taskbar PIN binds to one AUMID, so pins do not follow category+flips. Per-window: pick tile-tracks-state (varying appId) or pin continuity (stable appId) - never+both. pup: split mode varies, grouped mode keeps the stable pinnable Adom.Pup.++THE RETRY LESSON (how the first live test failed): the category flip fires right after a tab+opens, and the stamp resolves the window by its "(session: <id>)" title suffix - which the new+ACTIVE tab does not carry for a beat. The single-shot stamp silently returned false and the tile+stayed latched, while the AUMID registration (no window needed) succeeded, making the log look+half-done. Fixes that took it green: (1) stamp failures LOG their verdict (never silent-false a+shell operation), (2) the category re-stamp retries with backoff exactly like the auth-state path.+Verified live: first .mixed stamp FAILED on the title race, retry stamped it, tile repainted.+ ## The one-paragraph field guide (if you read nothing else)  pup misbehaving → **read `bridge_log_read` first.** Spawn-with-no-reap every ~N seconds = pup