dev-tools/scripts/addBackcompatIndexes.py doesn't work well with spotless [LUCENE-10298]
- Dominant language
- Java
- Stars
- 3.6k
- Forks
- 1.4k
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 88
Description
addBackcompatIndexes.py expects that lists of index names have one entry per line, e.g.
```Java
static final String oldNames = {
"xxxx"
}
```
However, when the array is small, Spotless forces the array to be written on a single line, and addBackcompatIndexes.py no longer recognizes the structure of the file.
It's probably fixable, but my Python skills are not good enough. Or maybe this file should be one of the rare ones that we exclude from Spotless?
---
Migrated from [LUCENE-10298](https://issues.apache.org/jira/browse/LUCENE-10298) by Adrien Grand (@jpountz)
Contributor guide
Research direction
Start with dev-tools/scripts/addBackcompatIndexes.py and inspect how it parses the index-name lists. Compare that logic with the single-line array layout produced by Spotless; done means the script recognizes both one-entry-per-line and compact single-line layouts.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, python
- Domain
- build-system, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100