debugging

Python assert -- improved introspection of failure?

This is a rather useless assertion error; it does not tell the values of the expression involved (assume constants used are actually variable names): $ python -c "assert 6-(3*2)" [...] AssertionError Is there a better assert implementation in Python that is more fancy? It must not introduce additional overhead over execution (except ...

Run multiple versions of Internet Explorer on Windows Vista

This question might belong to the Super User site, but then again: this is about debugging HTML, CSS and JavaScript. Am I able to run Internet Explorer 5.5, 6.0, 7.0 and 8.0 on a single Windows Vista install? If yes: how? Update: Duplicate of this question ...

Can I call a Win32 API from the Visual Studio Immediate Window?

I'm debugging a C++ Win32 application and I'd like to call an arbitrary Win32 API from the context of that process, as though the program had run this line of code: DestroyWindow(0x00021c0e); But entering that into the Immediate Window gives: CXX0017: Error: symbol "DestroyWindow" not found Edit: Using the full name of the function...

Print full signature of a method from a MethodInfo

Does anyone know of any existing functionality in the .NET BCL to print the full signature of a method at runtime (like what you'd see in the VS ObjectBrowser - including parameter names) using information available from MethodInfo? So for example, if you look up String.Compare() one of the overloads would print as: public static int C...

How can I find out more diagnostic information from a failed web service call?

When calling an asp.net web service from a windows mobile device project, I am catching an exception ( WebException ) and the response inside that seems to be "BadRequest". This is occurring on a live system but not locally in development. But they both have the same build.... When we point our development code at the live web service ...

does using try catch block in xcode show error on real device?

my application is running fine in simulator...but not on real device....and i have jailbroken iphone so i am unable to debug through device...if i use try catch something like this @try { Statements } @catch (NSException *ex) { UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Error" message:[NSString stringWithFormat:@"%@",ex...

In the Eclipse Debugger (for Java), is there a way to inspect arbitrary values?

I'm wondering if there is a way to look at the values of non-declared variables as they get passed into a function, after that function has been executed. For example, if I am debugging and the line foo.setBar(baz.getBar()); has already been passed (but is still within scope), how can I see the value of what got passed in to setBar()?...

Blackberry debugging with Intellij IDEA 8.0?

I have building a Blackberry project using bb-ant-tools working just fine. However, I cannot attach to the simulator. It says it is connected, but the simulator keeps saying "Debugger Attaching" and never finishes. Has anyone gotten this to work? ...

Step through JDK source code in IntelliJ IDEA

How can I step through JDK source code in IntelliJ IDEA 7 and see the debug info? I can currently hit breakpoints and step through the code, but the debug info is not available. This means I can't see the value of local variables. I only want to step through the source code of one class, if that matters. (For what it's worth, it's th...

Is optimization and generating debug info part of compilation or linkage

I am reading a Makefile from someone else as follows. LDFLAGS=-lm -ljpeg -lpng ifeq ($(DEBUG),yes) OPTIMIZE_FLAG = -ggdb3 -DDEBUG -fno-omit-frame-pointer else OPTIMIZE_FLAG = -ggdb3 -O3 endif CXXFLAGS = -Wall $(OPTIMIZE_FLAG) all: test test: test.o source1.o source2.o $(CXX) $(CXXFLAGS) -o $@ $^ $(LDFLAGS) M...

How to debug into system.servicemodel classes?

Hi All, How can i debug system.sevicemodel classes in my application? ...

Debugginng a daemon that terminates unexpectedly

I am writing a daemon in c on linux. It traps signals SIGHUP, SIGTERM, SIGINT, and SIGQUIT, logs them using syslog and quits. If it receives SIGSEGV it core dumps. When these occur everything happens as expected but once in a while it quits...does not exit cleanly, does not log the signal, and does not leave a core dump. I am stumped and...

Analysing a crash in Windows: what does the error message tell us?

A small utility of mine that I made for personal use (written in C++) crashed randomly yesterday (I've used it roughly 100+ hours with no issues so far) and while I don't normally do this, I was feeling a bit adventurous and wanted to try and learn more about the problem. I decided to go into the Event Viewer and see what Windows had log...

How to debug JavaFX

Hi all, I've just started working with javafx, it seems cool and NetBeans seems much more fun than Eclipse but I find it impossible to debug my application. I've added breakpoints, and I pressed the debug button, I see the debugger is registered to some port but it doesn't cause the application to start. When I run the application and ...

svctraceviewer for windows server 2003

I am trying to get the svctraceviewer installed on windows server 2003. I found that it's part of the Windows SDK which is of huge size. Moreover, i wouldn't want install Windows SDK on a server unless it's a hot patch. Is there a way to download or copy the tool separately(probably from windows vista)? Is there an alternative tool that...

Which programming technique helps you most to avoid or resolve bugs before they come into production

I don't mean external tools. I think of architectural patterns, language constructs, habits. I am mostly interested in C++ ...

Is it possible to debug .NET Class Library Methods as well?

With .NET Reflector we can see many .NET Class Library method's implementations. But is it possible to debug them as well? Or if I can put a break point inside them? ...

clever ways of tracking down bugs in Obj-C

I'm having a bug in my Objective C program which causes the machine to crash hip deep in some library methods, and it's all library methods down the stack to main (Which I haven't touched from the one XCode gave me). So, I have a bit of a mystery. The error I'm getting is: Program received signal: “EXC_BAD_ACCESS”. Now, I'm sure tha...

Can you explain this bizarre crash in the .NET runtime?

My C# application sends me a stack trace when it throws an unhandled exception, and I'm looking at one now that I don't understand. It looks as though this can't possibly be my fault, but usually when I think that I'm subsequently proved wrong. 8-) Here's the stack trace: mscorlib caused an exception (ArgumentOutOfRangeException): sta...

How best to debug a crash within objc_msgSend?

I have a crash taking place when an NSAutoreleasePool drains. Presumably the pool is trying to deallocate an object that has been prematurely released by another piece of code. The crash I have is in the midst of objc_msgSend as it is trying to send a message to an object that doesn't exist anymore. Given the stack state, what tips/tric...