You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucenenet.apache.org by GitBox <gi...@apache.org> on 2020/07/21 12:55:47 UTC

[GitHub] [lucenenet] NightOwl888 commented on pull request #313: Fix/random seed simple

NightOwl888 commented on pull request #313:
URL: https://github.com/apache/lucenenet/pull/313#issuecomment-661843488


   Its a bit strange, but although this seems to have fixed the `TestRandomStrings` tests for `TestICUFoldingFilter` and `TestThaiAnalyzer`, the `TestThaiAnalzyer::TestRandomHugeStrings()` test still fails. But digging into it, they both terminate in the same place, the only difference is the `maxWordLength` parameter is increased.
   
   I suspect we may have a difference in behavior somewhere in `TestUtil.RandomAnalysisString(Random, int, bool)` that may be causing some rare weirdness. Sadly, `TestUtil` has no tests to verify the behavior is doing what it should be doing.
   
   `TestUtil.RandomAnalysisString()` is also called by `Lucene.Net.Analysis.NGram.EdgeNGramTokenizerTest::TestFullUTF8Range()` and `Lucene.Net.Analysis.NGram.NGramTokenizerTest::TestFullUTF8Range()`, both which are also randomly failing. Perhaps one of the paths that `TestUtil.RandomSubString()` is going down is broken, which would explain the randomness. I suggest to divide and conquer - keep excluding the random paths until you find the one that causes the failure to stop happening. That would probably be a bit quicker than reviewing every one of those methods and comparing them against the Java implementation.


----------------------------------------------------------------
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.

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