Fix five small Explorer, search, and SUnit bugs (#532) - #537
Open
ericwinger wants to merge 2 commits into
Open
Conversation
The catch-all issue's items, each independent of the others. Source-scope search results came back in the stone's own traversal order. Those hits match a method body, so they carry no label match to rank on and every ranking rule tied; the tiebreak meant to catch them contradicted the shorter-label rule beside it, making the comparator cyclic — and a cyclic comparator lets Array.prototype.sort return anything. Method rows now order by one key: score, class A→Z, instance side before class side, selector. A step point number's hover said only which step point it was. The way to turn the numbers off sits far down the editor's right-click menu with no keybinding, so the hover now carries a "Hide step point numbers" link. Views moved out of the GemStone containers showed as a bare "Classes" or "Methods" next to everyone else's tabs. Each now declares a contextualTitle VS Code uses there, and the Rowan pane contributed into the file Explorer — which has no container heading of its own — is named GemStone Rowan. VS Code's own Testing, Test Results, Problems and Output tabs belong to the workbench and cannot be renamed by an extension. A class can now be dragged from the Classes pane onto a Class Categories row to refile it. An editor open on that class's definition re-reads: the category is a line of its source, so a stale buffer would have shown the old one and, on save, filed the class straight back. New Instance Method and New Class Method dropped into "as yet unclassified" whatever the Methods pane had selected. All three new-method entry points now read the same selection, still falling back when the selected category is on the other side. Run Test on a test method written after its class was listed reported "No tests found", and running the whole class silently skipped it. Running by name re-reads the class's methods first, and the empty-list message names what it looked for. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Four conflicts, all from work that landed on main in parallel: - main exported ClassItem too, for the tests that pin the class row's expansion chevron. Kept main's version and its comment, noting that the Classes pane's drag controller is the other caller. - main removed the Versions and Processes views, which the Databases & Versions panel supersedes. Their contextualTitle entries went with them; every remaining contributed view still declares one. - main moved the Explorer's unit tests into __tests__/explorer/. The new-method-category tests moved with them, and the class-category drag tests follow the same convention. - CHANGELOG: both sides only added entries, so both are kept. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
6 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #532 — five of the six items in that catch-all issue. Each is independent of the others.
GemStone Search: Source-scope results came back in no recognizable order
Those hits match a method body, so they carry no label match to rank on and every ranking rule tied. The tiebreak meant to catch them — same-selector rows sort by class A→Z — contradicted the shorter-label rule beside it, which made the comparator non-transitive, and a cyclic comparator lets
Array.prototype.sortreturn anything (here, the stone's traversal order nearly untouched).Method-like rows now order by one key rather than a rule that fires for some pairs and not others: score, then class A→Z, then instance side before class side, then selector. That is the same key the Methods provider already caps its own page with, so a row does not shift when the engine re-ranks it. Method-like and name-like categories never share a rank bucket, which is what keeps the whole comparator total.
Step point numbers: hover didn't say how to turn the view off
The tooltip said only which step point it was and that clicking toggles a breakpoint. The way out exists — Toggle Step Point Numbers — but sits far down the editor's right-click menu with no keybinding. The hover now carries a Hide step point numbers link.
isTrustedis scoped to that single command rather than granted wholesale.Workbench tabs: names (no badges)
Views dragged out of the GemStone containers showed as a bare "Classes" or "Methods" beside everyone else's tabs. Each contributed view now declares a
contextualTitleVS Code uses there, and the Rowan pane contributed into the file Explorer — which has no container heading of its own to name it — is GemStone Rowan outright. A manifest test pins this so the next view copy-pasted from a neighbour cannot ship without one.The badges half of that item is deliberately not done, so the checkbox stays open. A badge is set from the data the view last rendered, and VS Code only asks a tree for children while it is showing — so the count is right exactly when the rows are visible anyway, and stale the rest of the time. VS Code's own Testing, Test Results, Problems and Output tabs belong to the workbench and cannot be renamed by an extension.
Explorer: drag a class onto a class category to move it
A class row now drags from the Classes pane onto any Class Categories row, including a sub-category (it files into the full dashed path). Uncommitted, like every other Explorer write.
An editor open on that class's definition re-reads: the category is a line of definition source, so a stale buffer would have shown the old one and, on save, filed the class straight back — the definition save path applies its category line via
recategorizeClass. The file system provider gainednotifyChanged(uri)for stone-side changes nothing else announces.A new method lands in the selected method category
New Instance Method and New Class Method always passed
as yet unclassifiedwhatever the Methods pane had selected. All three entry points now read the same selection through one helper, still falling back when the selected category is on the other side — a category is per-side.Run Test on a newly added test method said "No tests found"
A class's test methods were listed once and never re-read, so a method written afterwards was missing: running it by name reported "No tests found", and running its whole class silently skipped it, until someone happened to hit Refresh SUnit Tests. Running by name now re-reads the class's methods first — one
discoverTestMethodsquery per run, next to running the tests themselves, nothing. The empty-list message names the class and selector it looked for.Testing
npm run lint,format:checkandcompileclean. Client 7302 passed / 12 skipped, server 322, mcp-server 92, against a live 3.6.2 stone with the server plugin installed.Each fix was mutation-checked — the fix reverted, the tests confirmed failing, the fix restored. Two tests that first passed against the broken code were rewritten: the "leaves open definitions alone on failure" case (the whole block is skipped when nothing moved, so the per-class filter needed a partial failure to exercise) and a badge test that used a second provider, which starts with nothing to clear.
One pre-existing flake is worth knowing about: the in-stone refactoring SUnit suites (
refactoringClass,refactoringMethod,refactoringInlineMethod) time out at vitest's 5s default under the full suite's parallel load. A different subset fails each run, each passes in isolation, andorigin/mainfails them the same way — I verified that against the same stone in a pristine worktree. Not from this branch.🤖 Generated with Claude Code