From 71fea1fd5ccb76e21942e60a36fff5c355b6a66f Mon Sep 17 00:00:00 2001 From: Craig Taverner Date: Tue, 24 Feb 2026 11:27:21 +0100 Subject: [PATCH 1/2] Added simpler test to focus on the key part that was failing --- .../apache/lucene/geo/TestTessellator.java | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/lucene/core/src/test/org/apache/lucene/geo/TestTessellator.java b/lucene/core/src/test/org/apache/lucene/geo/TestTessellator.java index 295e7929b377..72cb739f3b6e 100644 --- a/lucene/core/src/test/org/apache/lucene/geo/TestTessellator.java +++ b/lucene/core/src/test/org/apache/lucene/geo/TestTessellator.java @@ -953,6 +953,28 @@ public void testComplexPolygon64() throws Exception { checkMultiPolygon(polygons, 0.0); } + public void testComplexPolygon65() throws Exception { + // Simplified extract of the top-left corner of github-15731.geojson.gz: + // shell replaced with a bounding rectangle from the top-left-most shell vertex + // to a bottom-right cutoff point, with two surviving holes. + String geoJson = + """ + {"type": "Polygon", "coordinates": [ + [ + [-97.12583, 32.67035], [-97.12466, 32.67035], [-97.12466, 32.6691], + [-97.12583, 32.6691], [-97.12583, 32.67035] + ], [ + [-97.125074, 32.669464], [-97.125051, 32.669857], [-97.124884, 32.669819], + [-97.124906, 32.669464], [-97.124922, 32.669464], [-97.125074, 32.669464] + ], [ + [-97.124922, 32.669464], [-97.124716, 32.669445], [-97.124739, 32.669128], + [-97.124906, 32.669128], [-97.124922, 32.669464] + ] + ]}"""; + Polygon[] polygons = Polygon.fromGeoJSON(geoJson); + checkMultiPolygon(polygons, 0.0); + } + private static class TestCountingMonitor implements Tessellator.Monitor { private int count = 0; private int splitsStarted = 0; From a5bde98a780a689a3a405d84a5e5e00903210752 Mon Sep 17 00:00:00 2001 From: Craig Taverner Date: Tue, 24 Feb 2026 17:37:39 +0100 Subject: [PATCH 2/2] Add changes entry --- lucene/CHANGES.txt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lucene/CHANGES.txt b/lucene/CHANGES.txt index 824e4cb86b8b..ff587a512d29 100644 --- a/lucene/CHANGES.txt +++ b/lucene/CHANGES.txt @@ -247,6 +247,8 @@ Other --------------------- * GITHUB#15586: Document that scoring and ranking may change across major Lucene versions, and that applications requiring stable ranking should explicitly configure Similarity. (Parveen Saini) +* GITHUB#15764: Added simpler TestTesselator test in support of fix GITHUB#15731. (Craig Taverner) + ======================= Lucene 10.4.0 ======================= API Changes