Skip to content

[#2510] Retain subcommand suggestions with equal scores - #2534

Open
Mahmoodifar wants to merge 1 commit into
remkop:mainfrom
Mahmoodifar:fix/suggestion-score-ties
Open

Mahmoodifar wants to merge 1 commit into
remkop:mainfrom
Mahmoodifar:fix/suggestion-score-ties

Conversation

@Mahmoodifar

Copy link
Copy Markdown

With subcommands status, start, and stash, the input sta currently suggests only stash and status. The suggestion map drops start because it has the same similarity score as stash.

Keep all candidates for each score, preserving registration order within ties. Suggestions remain ordered by descending similarity and limited to three results. Regression tests cover tied candidates and the result limit; the existing demo expectation reflects the corrected tie order.

Refs #2510. This addresses the lost subcommand candidates; option-name similarity scoring remains outside this change.

Validation: both new regressions fail before the fix. The full core Gradle test suite passes on Java 17: 2,283 tests, 32 skipped, zero failures.

This branch has not been deployed

No deployments
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