Skip to content

fix(search): prevent stale command-dialog request state #74

Description

@llbbl

The command-palette search can expose stale loading and result state when requests overlap or when the dialog closes during an in-flight request. Request ownership and cancellation should ensure that only the active search can update UI state.

Acceptance

  • A superseded request cannot clear the loading state or replace results for a newer request.
  • Closing the search dialog aborts in-flight work and prevents late responses from repopulating state.
  • Reopening the dialog starts from a clean state without stale results or errors.
  • Tests cover overlapping requests, abort behavior, close/reopen behavior, and successful current-request results.
  • Formatting, linting, type checking, tests, local indexing, and the production build pass.

Tasks

  • gh-74-1 - Associate UI updates with the active search request.
  • gh-74-2 - Abort active work and reset safely when the dialog closes.
  • gh-74-3 - Add concurrency and close/reopen regression tests.
  • gh-74-4 - Run the full quality and build validation suite.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions