You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Shawn Heisey (JIRA)" <ji...@apache.org> on 2018/03/12 23:24:00 UTC
[jira] [Commented] (LUCENE-4545) Better error reporting
StemmerOverrideFilterFactory
[ https://issues.apache.org/jira/browse/LUCENE-4545?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16396237#comment-16396237 ]
Shawn Heisey commented on LUCENE-4545:
--------------------------------------
Found this issue because of a user having a problem. Uploaded a new patch against master (8.0).
[~rcmuir], I didn't use LineNumberReader as you suggested. I did find an example of that elsewhere in the code, but using that would have required a more substantial rewrite. I'm willing to do that if you really think that's the way it should be done, but I was able to get line numbers more directly than what the first patch did. The code has changed since the first patch was made.
I changed the regex in the split usage to any sequence of one or more whitespace characters, so it should be able to handle just about anything a user is likely to throw at it.
I did find a few other usages elsewhere of split with a single tab character. Some of them should perhaps be reviewed for adjustment to the "any whitespace" regex.
> Better error reporting StemmerOverrideFilterFactory
> ---------------------------------------------------
>
> Key: LUCENE-4545
> URL: https://issues.apache.org/jira/browse/LUCENE-4545
> Project: Lucene - Core
> Issue Type: Improvement
> Components: modules/analysis
> Affects Versions: 4.0
> Reporter: Markus Jelsma
> Priority: Trivial
> Fix For: 4.9, 6.0
>
> Attachments: LUCENE-4545-trunk-1.patch, LUCENE-4545.patch
>
>
> If the dictionary contains an error such as a space instead of a tab somewhere in the dictionary it is hard to find the error in a long dictionary. This patch includes the file and line number in the exception, helping to debug it quickly.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org