Please use the Apache issue tracking system for new NetBeans issues (https://issues.apache.org/jira/projects/NETBEANS0/issues) !!
Bug 187017 - java.util.regex.PatternSyntaxException: Dangling meta character '*' near index 0 * ^
java.util.regex.PatternSyntaxException: Dangling meta character '*' near inde...
Status: VERIFIED FIXED
Product: cnd
Classification: Unclassified
Component: Navigation
6.x
All All
: P2 (vote)
: 6.x
Assigned To: Andrey Yamkovoy
issues@cnd
EXCEPTIONS_REPORT 69patch2-verified
:
: 187182 188269 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-06-01 09:14 UTC by Alexander Simon
Modified: 2010-10-27 13:08 UTC (History)
8 users (show)

See Also:
Issue Type: DEFECT
:


Attachments
stacktrace (7.31 KB, text/plain)
2010-06-01 09:14 UTC, Alexander Simon
Details
stacktrace (7.32 KB, text/plain)
2010-07-06 04:50 UTC, Vladimir Kvashin
Details
stacktrace (7.14 KB, text/plain)
2010-07-23 09:52 UTC, jmichelberger
Details
stacktrace (1.32 KB, text/plain)
2010-07-24 19:58 UTC, kidnapper
Details
stacktrace (7.14 KB, text/plain)
2010-08-06 18:10 UTC, Michel Graciano
Details
stacktrace (7.13 KB, text/plain)
2010-08-06 18:20 UTC, Michel Graciano
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Simon 2010-06-01 09:14:12 UTC
Build: NetBeans IDE Dev (Build 100531-0be187cd4433)
VM: Java HotSpot(TM) Client VM, 16.3-b01, Java(TM) SE Runtime Environment, 1.6.0_20-b02
OS: SunOS

Stacktrace: 
java.util.regex.PatternSyntaxException: Dangling meta character '*' near index 0
*
^
   at java.util.regex.Pattern.error(Pattern.java:1713)
   at java.util.regex.Pattern.sequence(Pattern.java:1878)
   at java.util.regex.Pattern.expr(Pattern.java:1752)
   at java.util.regex.Pattern.compile(Pattern.java:1460)
   at java.util.regex.Pattern.<init>(Pattern.java:1133)
   at java.util.regex.Pattern.compile(Pattern.java:847)
Comment 1 Alexander Simon 2010-06-01 09:14:16 UTC
Created attachment 99698 [details]
stacktrace
Comment 2 Vladimir Kvashin 2010-07-06 04:50:27 UTC
Created attachment 100614 [details]
stacktrace

In C/C++ project, in Go to Type, I typed "*" in the name field - exception occurred
Comment 3 Exceptions Reporter 2010-07-23 08:58:02 UTC
This bug already has 5 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=170330
Comment 4 jmichelberger 2010-07-23 09:52:03 UTC
Created attachment 101001 [details]
stacktrace
Comment 5 kidnapper 2010-07-24 19:58:10 UTC
Created attachment 101012 [details]
stacktrace

Using ctrl + O to lookup *Login named classes
Comment 6 Alexei Mokeev 2010-07-26 12:24:15 UTC
*** Bug 188269 has been marked as a duplicate of this bug. ***
Comment 7 Alexei Mokeev 2010-07-26 12:24:47 UTC
*** Bug 187182 has been marked as a duplicate of this bug. ***
Comment 8 Michel Graciano 2010-08-06 18:10:58 UTC
Created attachment 101251 [details]
stacktrace
Comment 9 Michel Graciano 2010-08-06 18:12:50 UTC
After update fro 6.9.1 I can't use the Got to file since when I need to use * keyword.
Comment 10 Michel Graciano 2010-08-06 18:20:16 UTC
Created attachment 101253 [details]
stacktrace
Comment 11 Alexei Mokeev 2010-08-09 06:06:15 UTC
The roor reason is that pattern should be converted into correct regexp. 14 reports so far.
Comment 12 Andrey Yamkovoy 2010-08-17 14:43:59 UTC
Reproducible.
Comment 13 Andrey Yamkovoy 2010-08-17 14:52:50 UTC
Fixed in the main.
Comment 14 Michel Graciano 2010-08-17 19:06:00 UTC
changeset: main #331183437671

Thanks
Comment 15 Quality Engineering 2010-08-18 03:24:02 UTC
Integrated into 'main-golden', will be available in build *201008180001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/331183437671
User: Andrey Yamkovoy <kaktus@netbeans.org>
Log: Fix for #187017 - java.util.regex.PatternSyntaxException: Dangling meta character '*' near index 0 * ^
Comment 16 Vladimir Kvashin 2010-08-19 15:32:13 UTC
The fix caused the f
Comment 17 Vladimir Kvashin 2010-08-19 15:34:33 UTC
Sorry for incomplete comment. 
The fix causes regression:
previously such patterns as ".*" worked, now they do not.
Comment 18 Vladimir Kvashin 2010-08-19 15:40:25 UTC
In NB versions 6.1 through 6.9 (I didn't check earlier versions) patterns like ".*" worked. The ".*" pattern showed just all symbols.
Comment 19 Alexei Mokeev 2010-08-19 15:47:00 UTC
According to the description this field accepts wildcards, not the regexps.
In this sence ?* should work instead of .*

Just wondering how to distiguish regexp  w/o 'regexp' checkbox.
Comment 20 Vladimir Kvashin 2010-08-19 16:42:09 UTC
What you propose seems reasonable... but is changing the behavior right thing to do after it worked certain way for many releases? - that's the question. I believe we should just make it smarter.
Comment 21 Vladimir Kvashin 2010-08-19 16:51:39 UTC
What about simplistic decision: try treating it as a regexp, in the case we get an exception when compiling this regexp, we do the replacement you propose?
Comment 22 Vladimir Kvashin 2010-08-20 10:49:50 UTC
We finally agreed that, according to the text in the dialog, regular expressions are not supported. Only "?" and "*" wildcards are.
Comment 23 Egor Ushakov 2010-09-15 08:57:20 UTC
please nominate it for possible patch
Comment 24 Michel Graciano 2010-09-28 14:43:13 UTC
Any chance to backport it for 6.9?
Comment 25 Jiri Kovalsky 2010-09-29 12:49:47 UTC
Michel, I see this unrealistic. Unless, Andrey builds new module compatible with 6.9, has this tested fully and asks for publishing on the 6.9 UC. Andrey?
Comment 26 Michel Graciano 2010-09-29 12:58:40 UTC
Just let me know if I can help with anything. Of course I can help to test it without any problem.
Comment 27 Alexei Mokeev 2010-10-06 11:33:01 UTC
Hi Jirka, Andrey doesn't work any more in this area.
-Alexei.
Comment 28 Jiri Kovalsky 2010-10-06 12:04:23 UTC
And who does, Alexei?
Comment 29 Petr Suchomel 2010-10-18 09:18:37 UTC
Backported in release692 http://hg.netbeans.org/releases/rev/85ab93d72519
Comment 30 Alexander Pepin 2010-10-27 13:08:37 UTC
verified in patch2 candidate


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo