Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-1836

Flexible QueryParser fails with local different from en_US

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.9
    • Fix Version/s: 2.9
    • Component/s: modules/other
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      I get the following error during the mentioned testcases on my computer, if I use the Locale de_DE (windows 32):

          [junit] Testsuite: org.apache.lucene.queryParser.standard.TestQPHelper
          [junit] Tests run: 29, Failures: 1, Errors: 0, Time elapsed: 1,156 sec
          [junit]
          [junit] ------------- Standard Output ---------------
          [junit] Result: (fieldX:xxxxx fieldy:xxxxxxxx)^2.0
          [junit] ------------- ---------------- ---------------
          [junit] Testcase: testLocalDateFormat(org.apache.lucene.queryParser.standard.TestQPHelper): FAILED
          [junit] expected:<1> but was:<0>
          [junit] junit.framework.AssertionFailedError: expected:<1> but was:<0>
          [junit]     at org.apache.lucene.queryParser.standard.TestQPHelper.assertHits(TestQPHelper.java:1148)
          [junit]     at org.apache.lucene.queryParser.standard.TestQPHelper.testLocalDateFormat(TestQPHelper.java:1005)
          [junit]     at org.apache.lucene.util.LuceneTestCase.runTest(LuceneTestCase.java:201)
          [junit]
          [junit]
          [junit] Test org.apache.lucene.queryParser.standard.TestQPHelper FAILED
          [junit] Testsuite: org.apache.lucene.queryParser.standard.TestQueryParserWrapper
          [junit] Tests run: 27, Failures: 1, Errors: 0, Time elapsed: 1,219 sec
          [junit]
          [junit] ------------- Standard Output ---------------
          [junit] Result: (fieldX:xxxxx fieldy:xxxxxxxx)^2.0
          [junit] ------------- ---------------- ---------------
          [junit] Testcase: testLocalDateFormat(org.apache.lucene.queryParser.standard.TestQueryParserWrapper):       FAILED
          [junit] expected:<1> but was:<0>
          [junit] junit.framework.AssertionFailedError: expected:<1> but was:<0>
          [junit]     at org.apache.lucene.queryParser.standard.TestQueryParserWrapper.assertHits(TestQueryParserWrapper.java:1120)
          [junit]     at org.apache.lucene.queryParser.standard.TestQueryParserWrapper.testLocalDateFormat(TestQueryParserWrapper.java:985)
          [junit]     at org.apache.lucene.util.LuceneTestCase.runTest(LuceneTestCase.java:201)
          [junit]
          [junit]
          [junit] Test org.apache.lucene.queryParser.standard.TestQueryParserWrapper FAILED
      

      With en_US as locale it works.

        Attachments

        1. LUCENE-1836.patch
          9 kB
          Uwe Schindler
        2. LUCENE-1836.patch
          9 kB
          Uwe Schindler
        3. LUCENE-1836.patch
          9 kB
          Robert Muir
        4. LUCENE-1836.patch
          6 kB
          Robert Muir
        5. LUCENE-1836.patch
          1 kB
          Robert Muir
        6. LUCENE-1836.patch
          0.8 kB
          Robert Muir

          Issue Links

            Activity

              People

              • Assignee:
                michaelbusch Michael Busch
                Reporter:
                thetaphi Uwe Schindler
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: