Skip to content

Only refresh QtContextExplorer when visible and preserve in-flight state on same-thread ticks - #2275

Merged
trissim merged 1 commit into
mainfrom
fix/qt-context-panel-visible-bind
Nov 24, 2026
Merged

trissim merged 1 commit into
mainfrom
fix/qt-context-panel-visible-bind

Conversation

@trissim

@trissim trissim commented Nov 24, 2026

Copy link
Copy Markdown

Bug

ThreadSettingsPane.bind(view) calls self._context_panel.bind(view) on every coordination revision tick. Previously QtContextExplorer.bind(view) unconditionally called _cancel_background(), overwrote _search.setText(intent.query), and called present(force=True) — so every bus message on any channel:

  1. Fired background comms_context_inspection + native() fetches even when the Context panel was closed/hidden.
  2. Cancelled any in-flight native context fetch or search and wiped what the user was typing in _search, even when staying on the same thread.

Fix

  • QtContextExplorer.bind(view) only cancels background tasks, resets search/tree/detail, and passes force=True when view.thread_identity actually changed.
  • Only calls present(...) when self.isVisible().
  • Added showEvent calling self.present(force=False) so opening the Context panel loads immediately on demand.

Verification

  • Offscreen Qt test verifying hidden bind, showEvent, same-thread revision tick (preserves in-flight task & typed search text), and thread switch.
  • Guards: qt_inherit_ratchet.py, shadow_check.py, guarded_imports.py all 0, rel_imports=0, test_shared_frontend_members.py passed.

@trissim
trissim merged commit 72bef05 into main Nov 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant