question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Extension API: QuickPick fuzzy search not finding results

See original GitHub issue

Hi,

I use QuickPick component for opening daily notes in my extension.

Example: image

When I type -2d or -2 d I expect -2 days | Friday, July 24, 2020 Exists (see screenshot above) to appear in the results, but I see this instead:

image

Sorting is also wrong as -25 days item comes last in the results. In the order I provide it to QuickPick -25 comes before -172, -235, -263. Is it configurable?

Another example:

image

When I type +m I expect all Mondays with leading +n days to appear from previous screenshot, but I see this instead:

image

What could be the problem with it or am I missing something?

Thanks!

Issue Analytics

  • State:open
  • Created 3 years ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
bpaserocommented, Aug 14, 2020

Thanks, I can reproduce. I wonder if this possibly could be a duplicate of https://github.com/microsoft/vscode/issues/34088

However, I am not entirely sure why for example I can type “fr august” and it returns results:

image

Since the quick pick implementation was done by @chrmarti I would like to confirm with him and then we can close as duplicate. Maybe there is a rule in place that treats non-word characters such as - different.

0reactions
bpaserocommented, Aug 17, 2020

@chrmarti you can change to fuzzyScorer.scoreFuzzy or fuzzyScorer.scoreFuzzy2. The former is used by quick open for files and the latter for quick open for symbols (and intellisense).

There is a risk of breaking muscle memory though. Related: https://github.com/microsoft/vscode/issues/34088

Read more comments on GitHub >

github_iconTop Results From Across the Web

Quick Picks | Visual Studio Code Extension API
Quick Picks are an easy way to perform actions and receive input from the user. This is helpful when selecting a configuration option,...
Read more >
Text Editors | Metals - Scalameta
To find out how to set the version in your editor please check out the ... Fuzzy search a symbol in the workspace...
Read more >
Fuzzy Searches in VS Code: Tips to increase developer focus ...
The typescript extension, for example, only shows results where the whole sequence of characters is found together. But the C# extension has ...
Read more >
[vim/vim] Support for plugin authors needs to be improved ...
If the user pauses while searching I need to be able to cancel and reset the search but without closing and opening the...
Read more >
Changelog - SQLTools
Truncate query text not to explode result tab. ... Fix data type not showing for PG, MySQL and MSSQL. #595. Extension ... Adopted...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found