Bug 216408 - Compile on save and F6
Compile on save and F6
Status: NEW
Product: java
Classification: Unclassified
Component: Compiler
7.2
PC Mac OS X
: P3 (vote)
: 7.3
Assigned To: Dusan Balek
issues@java
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-08-05 11:31 UTC by fommil
Modified: 2012-08-09 13:58 UTC (History)
0 users

See Also:
Issue Type: DEFECT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description fommil 2012-08-05 11:31:08 UTC
I'm experiencing really weird behaviour with 7.2 and a Swing app (using Maven project, and worth noting, Lombok).

I have a JFrame application that I created using the GUI Editor, which is invoked on F6, and if I make any edit changes to the file and press F6 they are ignored.

Compile on Save (application and tests) is enabled.

Workaround: "Clean and Build" any time I edit the file.

Bizarrely, if I make changes in any other file with a main method and press shift-F6, the changes ARE seen.

Also, if I make changes in any other file and press F6, the changes are also seen.
Comment 1 Dusan Balek 2012-08-06 08:38:49 UTC
Unfortunately, I cannot reproduce the problem. Could you please create a simple reproducible test case (simple project + exact steps to reproduce) and attach it to the issue? Thanks.
Comment 2 fommil 2012-08-06 08:46:49 UTC
Bizarre, it seems to have fixed itself.

But I swear this *was* happening yesterday.

Is there any way for me to *absolutely guarantee* that "build" is called prior to a run? That way I can at least blame Maven if the classes aren't recompiled.
Comment 3 fommil 2012-08-09 12:25:58 UTC
not fixed - back again - and not just in JFrame. It is erratic and I can't create a standalone test.

As a workaround, is there any way to ensure that F6 calls "compile" before "run". Ideally, it would delete any "jar" that has been built. When I hit F6, I can drop to the terminal and "mvn compile" will update the binaries because Netbeans isn't compiling the files.
Comment 4 fommil 2012-08-09 13:58:19 UTC
Workaround: completely disable "compile on save" and the F6 etc commands will then invoke the correct Maven compilations.


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