-
Bug
-
Resolution: Done
-
Critical
-
None
-
None
-
2018 Week 45-47, 2018 Week 48-50, 2019 Week 02-04, 2018 Week 51-01
-
1
-
NEW
-
NEW
> Caused by: java.lang.ArithmeticException: / by zero
> at org.optaplanner.core.impl.heuristic.selector.value.chained.DefaultSubChainSelector.constructCache (DefaultSubChainSelector.java:139)
That DefaultSubChainSelector builds a List<SubChain> anchorTrailingChainList to cache some info,
to answer faster when having to select the next subchain.
When doing that, it presumes the anchorList.size() != 0, when giving a good capacity estimate.
That's clearly a bug.
int anchorChainInitialCapacity = ((int) valueSize / anchorList.size()) + 1;