Hi folks, There is a bug on master that I can't figure out.
The test LmOovFeatureTest.givenInputWithDifferentOovTypes_whenDecode_thenFeaturesAreAsExpected() fails when run on Linux without KenLM. I can repeat this problem by deleting $JOSHUA/lib/libken.so, and running cd $JOSHUA mvn test The output is [snip] ERROR - Can't find libken.so (libken.dylib on OS X) on the Java library path. WARN - sentence 0 too long 401, truncating to length 200 WARN - sentence 0 too long 401, truncating to length 200 WARN - sentence 0 too long 401, truncating to length 200 WARN - sentence 0 too long 401, truncating to length 200 Tests run: 107, Failures: 1, Errors: 0, Skipped: 12, Time elapsed: 1.89 sec <<< FAILURE! - in TestSuite givenInputWithDifferntOovTypes_whenDecode_thenFeaturesAreAsExpected(org.apache.joshua.system.LmOovFeatureTest) Time elapsed: 0.016 sec <<< FAILURE! java.lang.IndexOutOfBoundsException: Index: 1, Size: 0 at org.apache.joshua.system.LmOovFeatureTest.decode(LmOovFeatureTest.java:66) at org.apache.joshua.system.LmOovFeatureTest.givenInputWithDifferntOovTypes_whenDecode_thenFeaturesAreAsExpected(LmOovFeatureTest.java:59) Results : Failed tests: LmOovFeatureTest.givenInputWithDifferntOovTypes_whenDecode_thenFeaturesAreAsExpected:59->decode:66 ยป IndexOutOfBounds Tests run: 105, Failures: 1, Errors: 0, Skipped: 10 However, if I run Joshua manually on this test in either of the following ways, the test works fine: 1. cd $JOSHUA echo a chat-rooms full | joshua -config resources/lm_oov/joshua.config -outputformat "%f | %c" 2. cd $JOSHUA mvn -Dtest=LmOovFeatureTest test Finally, the error doesn't make sense: there is nothing to do with arrays on the specified lines, and I don't see where an IndexOutOfBoundsException could be coming from. Does anyone have any ideas what is going on? matt