apache / apache/lucene

TestForTooMuchCloning failing on 10x

Open
#15,661 3 comments 0 reactions 0 assignees View on GitHub
type:test
Dominant language
Java
Stars
3.6k
Forks
1.4k
Avg merge
2d 11h
Merged PRs (30d)
88

Description

### Description

While going through the release process, I noticed that 10x was failing pretty reliably for this test.

```
java.lang.AssertionError: too many calls to IndexInput.clone during TermRangeQuery: 36
at __randomizedtesting.SeedInfo.seed([CB64A16D4340F979:43309EB7EDBC9481]:0)
at org.junit.Assert.fail(Assert.java:89)
at org.junit.Assert.assertTrue(Assert.java:42)
at org.apache.lucene.index.TestForTooMuchCloning.test(TestForTooMuchCloning.java:95)
at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
at java.base/java.lang.reflect.Method.invoke(Method.java:580)
```

https://jenkins.thetaphi.de/job/Lucene-10.x-Linux/12083/testReport/junit/org.apache.lucene.index/TestForTooMuchCloning/test/

This same seed didn't fail on main, though I am not sure that means much :/

### Gradle command to reproduce

```
./gradlew test --tests TestForTooMuchCloning.test -Dtests.seed=CB64A16D4340F979 -Dtests.multiplier=3 -Dtests.locale=hsb -Dtests.timezone=Etc/GMT+1 -Dtests.asserts=true -Dtests.file.encoding=UTF-8
```

Contributor guide

Open the contributing guide

Research direction

Start with TestForTooMuchCloning.test and reproduce the failure using the Gradle command and seed provided in the issue. Inspect the assertion at TestForTooMuchCloning.java:95 and compare the result with main, where the same seed did not fail. Done means the 10.x test no longer reports excessive IndexInput.clone calls.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
testing
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.