Skip to content

SystemBrowser posts a redundant loadMethodCategories render with no selection before selecting the method's category #247

Description

@claude

Summary

When SystemBrowser navigates to a method, applyClassSelection (client/src/systemBrowser.ts:771)
posts loadMethodCategories twice: once with no selection, then again with the method's
actual category selected. Only the second post is needed — the first is a redundant
render that the webview has to process and repaint for.

Environment

  • Jasper: 1.7.4
  • GemStone server: N/A (pure client-side rendering issue)

Steps to reproduce

  1. Open the System Browser and navigate to any method (e.g. via SystemBrowser.navigateTo).
  2. Observe the sequence of loadMethodCategories messages posted to the webview.

Expected behavior

A single loadMethodCategories post with the method's category already selected.

Actual behavior

Two posts: { selected: null } followed by { selected: 'Accessing' } (or whatever the
method's actual category is) — confirmed by the test assertion
expect(categorySelections).toEqual([null, 'Accessing']).

Potential fix

applyClassSelection calls this.loadMethodCategories() with no argument before the
caller later re-invokes it with the resolved category (see client/src/systemBrowser.ts:777
and the later call sites around lines 891/929/1095). One approach could be to have
applyClassSelection accept/thread the target category through so it only posts once,
rather than posting an empty selection first.


Migrated from GitLab: GemStone/grail#54

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions