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.
Try and run welcome project: profiler is not on. Then try to remove the arguments and the profiler is now on. The cause is the function isSimpleRunCommand that now always returns false if run with arguments.
This is a showstopper for RC1. Please fix it ASAP following the HR FIX process.
The issue: The problem is it is impossible to know whether the command points to the binary the user do want to profile or to a runner, typically a shell but don't have to be, which the user probably don't wan to profile. I change the logic so it will turn off profiling when using most typical runners but it can be by-passed in which case the profiler will start. Starting profiler in these cases doesn't do any harm and the user can always explicitly turn it off so it should not be a problem. The fix: Instead of checking for a space (which doesn't work after we merged run command and arguments) in isSimpleRunCommand, I changed the logic to return false if the command starts with "/bin" or a known shell command like "sh", "bash", "csh". changeset: 191138:06e6342882cd tag: tip user: Thomas Preisler <thp@netbeans.org> date: Wed Mar 16 12:43:25 2011 -0700 summary: #196748 profiler is not on if run with arguments
*** Bug 193655 has been marked as a duplicate of this bug. ***
Integrated into 'main-golden', will be available in build *201103170400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/06e6342882cd User: Thomas Preisler <thp@netbeans.org> Log: #196748 profiler is not on if run with arguments
DIscussion with Igor/Andrew: OK, just to summarize it: Solution 1: public boolean isSimpleRunCommand() { String rc = runCommand.getValue().trim(); if (rc.startsWith("\"${")) { // default..... // NOI18N return true; } else if (makeConfiguration != null && makeConfiguration.isLibraryConfiguration()) { return true; } else if (rc.startsWith("/bin") || rc.startsWith("sh") || rc.startsWith("bash") || rc.startsWith("csh")) { // NOI18N return false; } else { return true; } } Solution 2: public boolean isSimpleRunCommand() { String rc = runCommand.getValue().trim(); if (rc.startsWith("\"${")) { // default..... // NOI18N return true; } else if (makeConfiguration != null && makeConfiguration.isLibraryConfiguration()) { return true; } else { return false; } } Solution 1: starts profiler in some (rare) cases where it doesn't work, but it is harmless and user can always turn it off. Solution 2: turns profiler off in some cases where it shouldn't but user cannot turn it on. Igor: I'm proposing to use Solution 2. It's more conservative, so user likely won't see any irrelevant data. And you are absolutely right that user can turn profiler on by force. thp: changed fix to Solution 2. Fix considered reviewed by Igor.
Second changeset: changeset: 191276:73fee75b7da3 tag: tip user: Thomas Preisler <thp@netbeans.org> date: Fri Mar 18 11:35:02 2011 -0700 summary: #196748 profiler is not on if run with arguments
Integrated into 'main-golden', will be available in build *201103190400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main/rev/73fee75b7da3 User: Thomas Preisler <thp@netbeans.org> Log: #196748 profiler is not on if run with arguments
verified in dev build #5002, please push the fix into release70 branch.
release70 changeset: changeset: 195149:4b9db51d04ab branch: release70 tag: tip parent: 195138:c305d435060c user: Thomas Preisler <thp@netbeans.org> date: Mon Mar 21 11:00:55 2011 -0700 summary: #196748 profiler is not on if run with arguments
verified in RC1 build 20110322.