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.
see : http://anna.nbextras.org/exceptions/detail.do?id=417 Exception comes from "org.yourorghere.module5.MyAction.performAction" that is not in the NB code base (of course ;) ), but selected component/subcomponent is "openide/actions" - that's wrong. I think we recommend "ide" as default in case reporter doesn't know which component has to be used.
The last NetBeans Class is: at org.openide.util.actions.CallableSystemAction$1.run(CallableSystemAction.java:96) Are you really sure that component: openide subcomponent: actions is incorrect for this use case? Please look at the stacktrace. java.lang.NullPointerException at org.yourorghere.module5.MyAction.performAction(MyAction.java:12) at org.openide.util.actions.CallableSystemAction$1.run(CallableSystemAction.java:96) at org.netbeans.modules.openide.util.ActionsBridge.doPerformAction(ActionsBridge.java:55) at org.openide.util.actions.CallableSystemAction.actionPerformed(CallableSystemAction.java:92) at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995) at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2318) at javax.swing.DefaultButtonModel.fireActionPerf
Zajo, I wrote module5.MyAction so I am sure ;) ---------------------------- String lll = null; public void performAction() { lll.toString(); } ----------------------------
You are probably sure... But there are some other usecases. What do you think about for example this one? java.lang.NullPointerException at java.io.FileInputStream.read at org.openide.util.actions.CallableSystemAction$1.run(CallableSystemAction.java:96) at org.netbeans.modules.openide.util.ActionsBridge.doPerformAction(ActionsBridge.java:55) at org.openide.util.actions.CallableSystemAction.actionPerformed(CallableSystemAction.java:92) Is the ide component appropriate now? And about this? http://anna.nbextras.org/exceptions/detail.do?id=284 There are some other issue: - exception is thrown from org.netbeans.module.unknown. The ide compontent is appropriate for this case - Issue #96051 Please tell us much better algorithm. We would like to improve it.
Created attachment 38984 [details] improvement to avoid core/code in everytime
I found solution for Marian's problem: org.yourorghere.module5.MyAction.performAction I experimentied with class resources url: System.out.println(getClass().getResource("bbbb.class")); It printed to system.out: jar:file:/tmp/org-yourorghere-module136364-test.jar!/org/yourorghere/module13/bbbb.class We can distinguish amount jar types: 1) developed application jar:file:/tmp/org-yourorghere-module136364-test.jar We can ignore exceptions for this line... 2) NetBeans module in netbeans home: jar:file:${netbeans.home}/${cluster}/modules/${code-name-base}.jar 3) External libraries in netbeans home: Other jars: jar:file:${netbeans.home}/*/${name}.jar 4) NetBeans module in userdir: jar:file:${user.home}/modules/${code-name-base}.jar 5) External libraries in userdir: Other jars: jar:file:${user.home}/*/${name}.jar 6) Exceptios from rt.jar jar:file:${java.home}/jre/lib/rt.jar!/* 7) Exception from other jars in jre/lib (Sometimes is usefull) jar:file:${java.home}/jre/lib/* 8) Exceptions in other location * I propose: 1)to create another one table in Exceptions db: JAR_FILE with columns: integer ID - primary key varchar(500) relpath - ralative path of jar byte type - (type of jar 1..8) add one more column to method item in stacktrace Integer JAR_FILE 2) If no issueazilla component was found for jar file we add special component for jar (iside reproter)type: 1 - "Developped module" (we can ignore these records) 2 - "Installed Module" 3 - "Installed Library" 4 - "User Modulle" 5 - "User Library" 6 - JDK 7 - JDK 8 - External Librrary Subcomponent name is: - code name base name - for regular - name of jar 3) Add UI (Excpetions web) for assigning correct component and subcomponent to jar file 4) Assigning correct component when someone called invalid API Typical Example: java.lang.IllegalArgumentException at org.openide.FileUtil.toFile... at org.marian.Experiments.. The issue is automatically reported against og.openide.filesystems Bit it is caused by at org.marian.Experiments.. I propose two solutions: a) based on statistics If there are reported a lot issues against: openide/filesystem The component is predicted from mapping: at org.openide.filesystems.FileUtil.toFile... org.openide.util -> openide/filesystems User users often changed the component and subcomponent to something else. We expects that that they changes it to different component (for example 5). We will ignore mapping for org.openide.util -> openide/filesystems and try use mapping for next item (recursion) ( org.marian.Experiments -> Developped Module ... b)Add UI for ignoring this line
The patch for core/code component was applied. Checking in src/java/org/netbeans/server/componentsmatch/Matcher.java; /cvs/logger/uihandlerserver/src/java/org/netbeans/server/componentsmatch/Matcher.java,v <-- Matcher.java new revision: 1.3; previous revision: 1.2 done Checking in test/org/netbeans/server/componentsmatch/MatcherTest.java; /cvs/logger/uihandlerserver/test/org/netbeans/server/componentsmatch/MatcherTest.java,v <-- MatcherTest.java new revision: 1.3; previous revision: 1.2 done
*** Issue 99686 has been marked as a duplicate of this issue. ***
2) jar files suggestions are done now, http://logger.netbeans.org/source/browse/logger/uihandlerserver/src/java/org/netbeans/server/componentsmatch/Matcher.java?r1=1.3&r2=1.4 reassinging components should be done in web application
using ide/code for unknown components Checking in DbInsertion.java; /cvs/logger/uihandlerserver/src/java/org/netbeans/server/uihandler/DbInsertion.java,v <-- DbInsertion.java new revision: 1.38; previous revision: 1.37 done
verified