debugging

R: How make dump.frames() include all variables for later post-mortem debugging with debugger()

眉间皱痕 提交于 2020-01-14 12:44:08
问题 I have the following code which provokes an error and writes a dump of all frames using dump.frames() as proposed e. g. by Hadley Wickham: a <- -1 b <- "Hello world!" bad.function <- function(value) { log(value) # the log function may cause an error or warning depending on the value } tryCatch( { a.local.value <- 42 bad.function(a) bad.function(b) }, error = function(e) { dump.frames(to.file = TRUE) }) When I restart the R session and load the dump to debug the problem via load(file = "last

Breakpoint set with IntelliJ not working in premain of remote custom java agent

三世轮回 提交于 2020-01-14 12:19:47
问题 I've started to implement a simple Java agent that does some instrumentation before a class is loaded by JVM. The thing is I need to do some debugging on this agent, but what I tried so far had failed( I tried to remote debug the agent but it's not working) I use IntelliJ and Maven( to generate the .jar agent). So my question:Is there any trick to remote debug a simple java agent? 回答1: As it turns out I have a project that demos Java instrumentation, which I have tested out debugging in

Breakpoint set with IntelliJ not working in premain of remote custom java agent

。_饼干妹妹 提交于 2020-01-14 12:19:25
问题 I've started to implement a simple Java agent that does some instrumentation before a class is loaded by JVM. The thing is I need to do some debugging on this agent, but what I tried so far had failed( I tried to remote debug the agent but it's not working) I use IntelliJ and Maven( to generate the .jar agent). So my question:Is there any trick to remote debug a simple java agent? 回答1: As it turns out I have a project that demos Java instrumentation, which I have tested out debugging in

Can breakpoints be used in ISRs?

风格不统一 提交于 2020-01-14 10:28:07
问题 Can breakpoints be used in interrupt service routines (ISRs)? 回答1: Yes - in an emulator . Otherwise, no. It's difficult to pull off, and a bad idea in any case. ISRs are (usually) supposed to work with the hardware, and hardware can easily behave very differently when you leave a gap of half a second between each instruction. Set up some sort of logging system instead. ISRs also ungracefully "steal" the CPU from other processes, so many operating systems recommend keeping your ISRs extremely

How to find slow-down in Javascript in IE6

為{幸葍}努か 提交于 2020-01-14 10:26:29
问题 Something's slowing down my Javascript code in IE6 to where there's a noticeable lag on hover. It's fine in FF, so using firebug isn't that helpful. What tools are out there to help debug this in IE? A little more info: I don't think there's actually any JS running on the objects that I'm mousing over. (At least none that I've put in.) Just css :hover stuff. Also, I've got both jquery and dojo running on the project, so who knows what they're doing in the background. 回答1: Just a tip of what

How to find slow-down in Javascript in IE6

孤街浪徒 提交于 2020-01-14 10:26:09
问题 Something's slowing down my Javascript code in IE6 to where there's a noticeable lag on hover. It's fine in FF, so using firebug isn't that helpful. What tools are out there to help debug this in IE? A little more info: I don't think there's actually any JS running on the objects that I'm mousing over. (At least none that I've put in.) Just css :hover stuff. Also, I've got both jquery and dojo running on the project, so who knows what they're doing in the background. 回答1: Just a tip of what

How can I hide an exception type from the output window in Visual Studio?

你说的曾经没有我的故事 提交于 2020-01-14 10:07:55
问题 I'm testing something and the output windows is being flooded with exceptions. How can I filter an exception type that is shown in the output window. Note: Avoiding exceptions is not possible in this case. 回答1: I do not believe this is possible. I think you can suppress all exceptions if a certain option is ticked but there is no way to filter the ones that are displayed. 回答2: Hiding an exception type is not possible as I know. But to filter out all exception messages, right click output

How can I hide an exception type from the output window in Visual Studio?

泪湿孤枕 提交于 2020-01-14 10:07:37
问题 I'm testing something and the output windows is being flooded with exceptions. How can I filter an exception type that is shown in the output window. Note: Avoiding exceptions is not possible in this case. 回答1: I do not believe this is possible. I think you can suppress all exceptions if a certain option is ticked but there is no way to filter the ones that are displayed. 回答2: Hiding an exception type is not possible as I know. But to filter out all exception messages, right click output

Very strange error caused by html whitespace

孤人 提交于 2020-01-14 09:36:08
问题 I have encountered a very strange bug in Firefox. I have a javascript function in an external file that works perfectly on regular complexity websites. However I have been putting together a few demonstration examples and come across something odd. With html formatted like this (in an editor): <div><p>Q: Where's the rabbit?</p><p class="faq_answer">A: I don't know, honest</p></div> The Javascript works as expected. However when like this: <div> <p>Q: Where's the rabbit?</p> <p class="faq

Near empty Java For-Loop acts strange

你离开我真会死。 提交于 2020-01-14 09:10:48
问题 This code acts as expected printing "Average Number of Runs: 0.99864197" import java.util.Random; public class A { public static void main(String[] args) { int min = -30; int max = 1; test(min, max); } static void test(int min, int max){ int count = 0; Random rand = new Random(0); for(int j = 0; j < 2097152; j++){ int number = min + rand.nextInt(max-min+1); for(int i = 0; i < number; ++i) { System.out.print(""); count++; } } System.out.println("Average Number of Runs: " + count/65536F); } }