You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucene.apache.org by "easyice (via GitHub)" <gi...@apache.org> on 2024/02/04 03:47:23 UTC

[PR] Fix NPE in TestReqOptSumScorer.testFilterRandomRareOpt [lucene]

easyice opened a new pull request, #13069:
URL: https://github.com/apache/lucene/pull/13069

   The value `C` of field `f` may not appear in all segments.
   
   
   ```
      >     java.lang.NullPointerException: Cannot invoke "org.apache.lucene.search.Scorer.twoPhaseIterator()" because "s2" is null
      >         at __randomizedtesting.SeedInfo.seed([E000CB24BEEF3CDA:634D0259C7E92DEB]:0)
      >         at org.apache.lucene.tests.search.CheckHits.doCheckMaxScores(CheckHits.java:738)
      >         at org.apache.lucene.tests.search.CheckHits.checkTopScores(CheckHits.java:698)
      >         at org.apache.lucene.search.TestReqOptSumScorer.doTestRandom(TestReqOptSumScorer.java:379)
      >         at org.apache.lucene.search.TestReqOptSumScorer.testFilterRandomRareOpt(TestReqOptSumScorer.java:267)
   ```
   
   It cannot be reproduced stably, but there is a high probability.
   
   ```
   ./gradlew test --tests TestReqOptSumScorer.testFilterRandomRareOpt -Dtests.seed=E000CB24BEEF3CDA -Dtests.nightly=true -Dtests.locale=hsb-DE -Dtests.timezone=Africa/Djibouti -Dtests.asserts=true -Dtests.file.encoding=UTF-8
   ```
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org


Re: [PR] Fix NPE in TestReqOptSumScorer.testFilterRandomRareOpt [lucene]

Posted by "jpountz (via GitHub)" <gi...@apache.org>.
jpountz commented on PR #13069:
URL: https://github.com/apache/lucene/pull/13069#issuecomment-1931937257

   Hmm actually we should probably assert that s1.iterator().nextDoc() returns NO_MORE_DOCS in this `if` block, to make sure that both scorers produce the same hits? @easyice Can you open a follow-up PR?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org


Re: [PR] Fix NPE in TestReqOptSumScorer.testFilterRandomRareOpt [lucene]

Posted by "dweiss (via GitHub)" <gi...@apache.org>.
dweiss merged PR #13069:
URL: https://github.com/apache/lucene/pull/13069


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org


Re: [PR] Fix NPE in TestReqOptSumScorer.testFilterRandomRareOpt [lucene]

Posted by "easyice (via GitHub)" <gi...@apache.org>.
easyice commented on PR #13069:
URL: https://github.com/apache/lucene/pull/13069#issuecomment-1931685251

   Thanks for reviewing! @dweiss @jpountz 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org


Re: [PR] Fix NPE in TestReqOptSumScorer.testFilterRandomRareOpt [lucene]

Posted by "easyice (via GitHub)" <gi...@apache.org>.
easyice commented on PR #13069:
URL: https://github.com/apache/lucene/pull/13069#issuecomment-1931077803

   This will also fix test failure for TestReqOptSumScorer.testFilterRandomFrequentOpt
   
   ```
   ./gradlew test --tests TestReqOptSumScorer.testFilterRandomFrequentOpt -Dtests.seed=70A6B2258BEC1D96 -Dtests.nightly=true -Dtests.locale=mni-Beng-IN -Dtests.timezone=America/Indianapolis -Dtests.asserts=true -Dtests.file.encoding=UTF-8
   ``` 
   
   
   ```
   org.apache.lucene.search.TestReqOptSumScorer > testFilterRandomFrequentOpt FAILED
       java.lang.NullPointerException: Cannot invoke "org.apache.lucene.search.Scorer.twoPhaseIterator()" because "s2" is null
           at __randomizedtesting.SeedInfo.seed([70A6B2258BEC1D96:94B3EF7331EC2DC4]:0)
           at org.apache.lucene.tests.search.CheckHits.doCheckMaxScores(CheckHits.java:737)
           at org.apache.lucene.tests.search.CheckHits.checkTopScores(CheckHits.java:698)
           at org.apache.lucene.search.TestReqOptSumScorer.doTestRandom(TestReqOptSumScorer.java:379)
           at org.apache.lucene.search.TestReqOptSumScorer.testFilterRandomFrequentOpt(TestReqOptSumScorer.java:263)
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org


Re: [PR] Fix NPE in TestReqOptSumScorer.testFilterRandomRareOpt [lucene]

Posted by "easyice (via GitHub)" <gi...@apache.org>.
easyice commented on PR #13069:
URL: https://github.com/apache/lucene/pull/13069#issuecomment-1933281709

   Nice catch! I will fix it.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@lucene.apache.org
For additional commands, e-mail: issues-help@lucene.apache.org