Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing groups from GroupingSearch #964

Open
1 task done
dongle-the-gadget opened this issue Sep 27, 2024 · 1 comment
Open
1 task done

Missing groups from GroupingSearch #964

dongle-the-gadget opened this issue Sep 27, 2024 · 1 comment
Assignees
Labels

Comments

@dongle-the-gadget
Copy link

dongle-the-gadget commented Sep 27, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Describe the bug

GroupingSearch might miss some groups, even if searching for docs using IndexSearcher.Search indicates that the group should be present.

For instance, using IndexSearcher.Search will reveal a document with field name and value CreateFileW, but using GroupingSearch, like below:

GroupingSearch groupingSearch = new("name");
groupingSearch.SetAllGroups(true);

// query here works with IndexSearcher.Search
var groups = groupingSearch.Search(searcher, query, 0, 10);

// groups variable doesn't contain all the possible groups.

contains no group with the name being CreateFileW.

In addition, the TotalGroupCount is inconsistent with that of the real dataset (in the repro below GroupingSearch returns 4 instead of the expected 10).

Expected Behavior

The group should exist in the search, and there should not be a mismatch between TotalGroupCount and the index.

Steps To Reproduce

A repro repository is here: https://github.com/dongle-the-gadget/TestLucene

The real dataset has documents of the following names:

CreateFile2
CreateFile2FromAppW
CreateFileA
CreateFileFromAppW
CreateFileMappingA
CreateFileMappingFromApp
CreateFileMappingW
CreateFileMoniker
CreateFileW
CreateFile2

Exceptions (if any)

No response

Lucene.NET Version

4.8.0-beta00016

.NET Version

8.0

Operating System

Windows 11

Anything else?

No response

@paulirwin paulirwin self-assigned this Oct 28, 2024
@paulirwin paulirwin added this to the 4.8.0-beta00018 milestone Oct 28, 2024
@paulirwin
Copy link
Contributor

I'll take investigating this one for the beta 18 release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants