acsbendi opened a new pull request, #1054: URL: https://github.com/apache/solr/pull/1054
# Description This change fixes the following exception: ``` 2022-10-04 12:21:26.033 ERROR (qtp503938393-25) [...] o.a.s.c.s.i.s.ExceptionStream java.lang.IndexOutOfBoundsException: Index 0 out of bounds for length 0 => java.lang.IndexOutOfBoundsException: Index 0 out of bounds for length 0 at java.base/jdk.internal.util.Preconditions.outOfBounds(Unknown Source) java.lang.IndexOutOfBoundsException: Index 0 out of bounds for length 0 at jdk.internal.util.Preconditions.outOfBounds(Unknown Source) ~[?:?] at jdk.internal.util.Preconditions.outOfBoundsCheckIndex(Unknown Source) ~[?:?] at jdk.internal.util.Preconditions.checkIndex(Unknown Source) ~[?:?] at java.util.Objects.checkIndex(Unknown Source) ~[?:?] at java.util.ArrayList.get(Unknown Source) ~[?:?] at [org.apache.solr.client.solrj.io](http://org.apache.solr.client.solrj.io/).eval.RecursiveNumericEvaluator.normalizeInputType(RecursiveNumericEvaluator.java:55) ~[?:?] at [org.apache.solr.client.solrj.io](http://org.apache.solr.client.solrj.io/).eval.RecursiveEvaluator.recursivelyEvaluate(RecursiveEvaluator.java:214) ~[?:?] at [org.apache.solr.client.solrj.io](http://org.apache.solr.client.solrj.io/).eval.RecursiveEvaluator.evaluate(RecursiveEvaluator.java:202) ~[?:?] at [org.apache.solr.client.solrj.io](http://org.apache.solr.client.solrj.io/).stream.LetStream.open(LetStream.java:195) ~[?:?] at [org.apache.solr.client.solrj.io](http://org.apache.solr.client.solrj.io/).stream.ExceptionStream.open(ExceptionStream.java:49) ~[?:?] at org.apache.solr.handler.StreamHandler$TimerStream.open(StreamHandler.java:486) ~[?:?] at [org.apache.solr.client.solrj.io](http://org.apache.solr.client.solrj.io/).stream.TupleStream.writeMap(TupleStream.java:77) ~[?:?] at org.apache.solr.common.util.JsonTextWriter.writeMap(JsonTextWriter.java:168) ~[?:?] at org.apache.solr.common.util.TextWriter.writeMap(TextWriter.java:241) ~[?:?] at org.apache.solr.common.util.TextWriter.writeVal(TextWriter.java:85) ~[?:?] at org.apache.solr.response.TextResponseWriter.writeVal(TextResponseWriter.java:205) ~[?:?] at org.apache.solr.common.util.TextWriter.writeVal(TextWriter.java:45) ~[?:?] at org.apache.solr.common.util.JsonTextWriter.writeNamedListAsMapWithDups(JsonTextWriter.java:387) ~[?:?] at org.apache.solr.common.util.JsonTextWriter.writeNamedList(JsonTextWriter.java:295) ~[?:?] at org.apache.solr.response.JSONWriter.writeResponse(JSONWriter.java:77) ~[?:?] at org.apache.solr.response.JSONResponseWriter.write(JSONResponseWriter.java:63) ~[?:?] at org.apache.solr.response.QueryResponseWriterUtil.writeQueryResponse(QueryResponseWriterUtil.java:71) ~[?:?] at org.apache.solr.servlet.HttpSolrCall.writeResponse(HttpSolrCall.java:999) ~[?:?] at org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:631) ~[?:?] at org.apache.solr.servlet.SolrDispatchFilter.dispatch(SolrDispatchFilter.java:239) ~[?:?] at org.apache.solr.servlet.SolrDispatchFilter.lambda$doFilter$0(SolrDispatchFilter.java:207) ~[?:?] at org.apache.solr.servlet.ServletUtils.traceHttpRequestExecution2(ServletUtils.java:257) ~[?:?] at org.apache.solr.servlet.ServletUtils.rateLimitRequest(ServletUtils.java:227) ~[?:?] at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:202) ~[?:?] ``` # Solution I check if the list if empty before accessing its first item. # Tests # Checklist Please review the following and check all that apply: - [ ] I have reviewed the guidelines for [How to Contribute](https://wiki.apache.org/solr/HowToContribute) and my code conforms to the standards described there to the best of my ability. - [ ] I have created a Jira issue and added the issue ID to my pull request title. - [ ] I have given Solr maintainers [access](https://help.github.com/en/articles/allowing-changes-to-a-pull-request-branch-created-from-a-fork) to contribute to my PR branch. (optional but recommended) - [ ] I have developed this patch against the `main` branch. - [ ] I have run `./gradlew check`. - [ ] I have added tests for my changes. - [ ] I have added documentation for the [Reference Guide](https://github.com/apache/solr/tree/main/solr/solr-ref-guide) -- 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-unsubscr...@solr.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For additional commands, e-mail: issues-h...@solr.apache.org