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.
From Versioning view I double-clicked modified file and got: java.lang.AssertionError at org.netbeans.modules.editor.completion.CompletionImpl.stateChanged(CompletionImpl.java:270) at org.netbeans.editor.Registry.fireChange(Registry.java:489) at org.netbeans.editor.Registry.activate(Registry.java:231) at org.netbeans.editor.BaseTextUI.installUI(BaseTextUI.java:228) at javax.swing.JComponent.setUI(JComponent.java:652) at javax.swing.text.JTextComponent.setUI(JTextComponent.java:298) at org.netbeans.editor.BaseKit.install(BaseKit.java:486) at javax.swing.JEditorPane.setEditorKit(JEditorPane.java:959) at javax.swing.JEditorPane.setContentType(JEditorPane.java:886) at org.netbeans.modules.diff.builtin.visualizer.DiffViewImpl.setMimeType1(DiffViewImpl.java:635) at org.netbeans.modules.diff.builtin.visualizer.DiffViewImpl.<init>(DiffViewImpl.java:132) at org.netbeans.modules.diff.builtin.DefaultDiff.createDiff(DefaultDiff.java:112) at org.netbeans.modules.versioning.system.cvss.ui.actions.diff.DiffMainPanel$DiffPrepareTask.run(DiffMainPanel.java:517) at org.openide.util.Task.run(Task.java:207) at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:469) [catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:870)
100% reproducible. No diffs available anymore.
please, do not set content type outside awt thread. It is not thread safe operation. Reassigning.
I do not understand. Component is not visible nor added to AWT hiearchy. In such case it should be legal to call any method from any thread AFAIK. I can workaround but at price of blocking AWT for long time.
Workarounded in CVS: Checking in DiffMainPanel.java; /cvs/javacvs/cvsmodule/src/org/netbeans/modules/versioning/system/cvss/ui/actions/diff/DiffMainPanel.java,v <-- DiffMainPanel.java new revision: 1.13; previous revision: 1.12 done Checking in Setup.java; /cvs/javacvs/cvsmodule/src/org/netbeans/modules/versioning/system/cvss/ui/actions/diff/Setup.java,v <-- Setup.java new revision: 1.9; previous revision: 1.8 done Checking in DiffStreamSource.java; /cvs/javacvs/cvsmodule/src/org/netbeans/modules/versioning/system/cvss/ui/actions/diff/DiffStreamSource.java,v <-- DiffStreamSource.java new revision: 1.8; previous revision: 1.7 done
Petr, is the issue fixed?
Workarounded at CVS side. Still I think that the assert is incorrect (see above).
I am not sure it is legal. Recently, I have added also asserts to BaseKit.install and BaseKit.deinstall to ensure the operation runs in AWT thread. We have been already solving several deadlocks, NPEs or other weird things that happend after incorrect installation outside awt thread. Please read the "Note" in: http://java.sun.com/docs/books/tutorial/uiswing/misc/threads.html#EDT It seems that the using of non awt thread before component realization was revisited.
Thanks for explanation. I have not been aware of the recent conclusion. OK, it's javacvs bug then. It's FIXED.
Checking in DiffResultsView.java; /shared/data/ccvs/repository/javacvs/cvsmodule/src/org/netbeans/modules/versioning/system/cvss/ui/history/DiffResultsView.java,v <-- DiffResultsView.java new revision: 1.9; previous revision: 1.8 done