This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 235666 - JavacParser fails to parse SQLInsertClause.java
Summary: JavacParser fails to parse SQLInsertClause.java
Status: VERIFIED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Project (show other bugs)
Version: 7.4
Hardware: PC Windows 7
: P2 normal (vote)
Assignee: Tomas Zezula
URL:
Keywords: 7.4_HR_FIX
Depends on:
Blocks:
 
Reported: 2013-09-09 03:16 UTC by _ gtzabari
Modified: 2013-09-26 18:14 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
messages.log (49.81 KB, application/octet-stream)
2013-09-09 03:16 UTC, _ gtzabari
Details

Note You need to log in before you can comment on or make changes to this bug.
Description _ gtzabari 2013-09-09 03:16:03 UTC
Created attachment 139815 [details]
messages.log

Product Version: NetBeans IDE Dev (Build 201309080001)
Java: 1.7.0_40; Java HotSpot(TM) 64-Bit Server VM 24.0-b55
Runtime: Java(TM) SE Runtime Environment 1.7.0_40-b40
System: Windows 7 version 6.1 running on amd64; Cp1252; en_CA (nb)
User directory: C:\Users\Gili\AppData\Roaming\NetBeans\dev
Cache directory: C:\Users\Gili\AppData\Local\NetBeans\Cache\dev

1. Clean userdir

2. Create an Ant project with QueryDSL on the compile classpath and querydsl-sql-3.2.3-sources.jar listed as a source JAR

3. Open com.mysema.query.sql.dml.SQLInsertClause

4. Netbeans fails to find the source-code, and instead shows a disassembled class file.

5. See the attached messages.log which contains the following exception:

WARNING [org.netbeans.modules.java.source.parsing.JavacParser]: ClassPath identity changed for C:\Users\Gili\AppData\Local\NetBeans\Cache\dev\index\s48\java\14\gensrc\com\mysema\query\sql\dml\SQLInsertClause.java@89a0b3aa:791ac03b, class path owner: null original sourcePath: C:\Users\Gili\Documents\pill\core\src;C:\Users\Gili\Documents\pill\core\build\generated-sources\java new sourcePath: null
Comment 1 _ gtzabari 2013-09-09 03:17:05 UTC
Increased priority as I believe this is a regression.
Comment 2 Svata Dedic 2013-09-09 11:16:19 UTC
OK, I need more precise steps perhaps. Here is what I did, please correct the scenario, since I it not produce the error you've described.

1/ clean userdir
2/ created Java Application project
3/ added all JARs from querydsl-sql/lib/all
4/ for querydsl-sql, defined source JAR querydsl-sql/src/querydsl-sql-3.2.3-sources.jar
5/ opened SQLInsertClause, com.mysema.query.sql.dml.SQLInsertClause

the appropriate source file opened.

Please also justify the originally assigned priority. The behaviour may not be new, at least the exception was already reported as part of issue #201511, issue #192647, behaviour of not finding the appropriate source in issue #204039. 

It's true that the current bugzilla rules say "regression = P1", but please interpret the condition in the context of P1 definition "Product feature does not work, no workaround exists".

During creating the reproduction scenario, please observe how many choices you'll be offered when you enter SQLInsertClause into Goto Type dialog. If there's the _proper_ source listed among the library files, then the defect is clearly P3 - since a viable workaround exists.
Comment 3 _ gtzabari 2013-09-10 04:59:15 UTC
Hi Svata,

Here are the updated repro steps:

1. Download http://www.querydsl.com/static/querydsl/3.2.3/querydsl-sql-codegen-3.2.3-full-deps.zip
2. Netbeans build 201309080001
3. Delete both userdir and cache directories
4. Launch Netbeans
5. Create Java Application project
6. Project -> Properties -> Libraries -> Browse -> (create a library folder)
7. Add Library -> Create -> QueryDSL -> Classpath -> Add all of querydsl-sql-8odegen-3.2.3/lib/all
9. Sources -> Add all of querydsl-sql-codegen-3.2.3/src
10. Ok -> Ok (save the project properties)
11. CTRL+O (go to type)
12. SQLInsertClause
13. Only one entry will show up, select it.
14. Notice that the source is not found and a disassembled view is returned.

I will attach my project for your review.
Comment 4 _ gtzabari 2013-09-10 05:02:02 UTC
The project is bigger than I expected (7MB). You can temporarily download it from http://bbs.darktech.org/issue235666.zip. I will delete this file once you are done with it.

Let me know if you can now reproduce the issue.
Comment 5 David Strupl 2013-09-10 11:55:10 UTC
I agree with Svata --> this is not a P1 problem. Making it P3. If it is likely that this will impact more users let's make it P2.
Comment 6 Jiri Prox 2013-09-10 12:01:43 UTC
I can reproduce it now

the problem seems to be in relative path to the library. I've added the jars using absolute path (e.g. not copy to the lib folder) and it works fine.
Comment 7 Svata Dedic 2013-09-10 12:49:15 UTC
IMHO a j2se project issue
Comment 8 _ gtzabari 2013-09-11 03:33:05 UTC
This should be at least a P2.

Maven projects are also affected, and in that case there is no workaround (I don't get to choose relative vs absolute paths). So to reiterate:

This is a regression.
There is no workaround.

At the very least, target milestone should be set for 7.4. I view this bug as a showstopper: the release should not ship with this bug open.
Comment 9 Tomas Zezula 2013-09-17 08:27:57 UTC
Fixed jet-main 6120f4cc0f37

>This should be at least a P2.
I agree that it deserves P2. Please increase the priority if you want.
Comment 10 _ gtzabari 2013-09-17 15:22:43 UTC
Thanks for the fix. I've increased priority in the hopes of increasing the odds this that gets integrated into 7.4 final.
Comment 11 _ gtzabari 2013-09-17 15:24:30 UTC
BTW, at what point does "Target Milestone" get set? Usually I see it get set before the issue is resolved and a decision is made later on as to whether to include it with the release or not.
Comment 12 Tomas Zezula 2013-09-17 16:02:38 UTC
The Target Milestone is set to Dev, when QA agrees that it belongs to NB 7.4 we add the 74_HR_FIX_CANDIDATE keyword. When the fix is transplanted to 7.4 we change the 74_HR_FIX_CANDIDATE to 74_HR_FIX and update the Target Milesone to 7.4
Comment 13 _ gtzabari 2013-09-17 16:35:11 UTC
Thanks for the clarification Tomas :)
Comment 14 Jiri Prox 2013-09-18 08:43:59 UTC
verified in trunk
Comment 15 Marian Mirilovic 2013-09-18 08:46:48 UTC
(In reply to Tomas Zezula from comment #12)
> The Target Milestone is set to Dev, when QA agrees that it belongs to NB 7.4
> we add the 74_HR_FIX_CANDIDATE keyword. When the fix is transplanted to 7.4
> we change the 74_HR_FIX_CANDIDATE to 74_HR_FIX and update the Target
> Milesone to 7.4

QE agrees, please proceed with integration.
Comment 16 Dusan Balek 2013-09-20 09:36:11 UTC
The fix seems to be OK.
Comment 17 Tomas Zezula 2013-09-24 13:21:46 UTC
Transplanted into NB 7.4
http://hg.netbeans.org/releases/rev/dfa1e2baa756
Comment 18 Quality Engineering 2013-09-25 23:59:53 UTC
Integrated into 'releases/release74', will be available in build *201309252201* or newer. Wait for official and publicly available build.

Changeset: http://hg.netbeans.org/releases/rev/dfa1e2baa756
User: Tomas Zezula <tzezula@netbeans.org>
Log: #235666:JavacParser fails to parse SQLInsertClause.java
Comment 19 Jiri Prox 2013-09-26 18:14:51 UTC
verified in 7.4 RC2