Catching AI crashes with VS.net debugger

Catching AI crashes with VS.net debugger

Here is where ideas can be collected for the skirmish AI in development

Moderators: hoijui, Moderators

Post Reply
submarine
AI Developer
Posts: 834
Joined: 31 Jan 2005, 20:04

Catching AI crashes with VS.net debugger

Post by submarine »

Unfortunately, since spring 0.72 i`m not able to catch crasehs with the debugger anymore. I used to run spring in windowed mode attaching the debugger to the spring.exe at the beginning of the game. i never experienced any problems

however since spring 0.72 this doenst work anymore, spring just quits without the debugger even noticing it. krogothe reported the same problem.

does anyone know how to fix this? it's fairly impossible to continue development effectively without being able to use the debugger

@devs: did you change anything in the project settings?
User avatar
krogothe
AI Developer
Posts: 1050
Joined: 14 Nov 2005, 17:07

Post by krogothe »

I can confirm that, it seems the debugger stopped working completely, no error messages, no bug report form. After coding 5 months without knowing about the debugger i can survive, but even after one month of using i miss it like a hole in the head :)
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

NTai is acting strange in the debugger.


When I get to a point where I can get a crash in the debugger, all the NTai.dll entries are greyed out and it says there's no source or information of them.

You should all try turning off AI exception handling in settings.exe
User avatar
krogothe
AI Developer
Posts: 1050
Joined: 14 Nov 2005, 17:07

Post by krogothe »

AF wrote: You should all try turning off AI exception handling in settings.exe
patronizing ftl, youd think your fellow AI developers would try that before coming here :wink:
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

=s
User avatar
unpossible
Posts: 871
Joined: 10 May 2005, 19:24

Post by unpossible »

do we want this on when we're trying to watch for bugs/crashes etc? does it make a difference?
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

It definately makes a difference.

Debuggers wont break on exceptions if they're encased in a try catch block
submarine
AI Developer
Posts: 834
Joined: 31 Jan 2005, 20:04

Post by submarine »

it must be disabled, otherwise spring will catch the exception itself.

but off course i presume we all disabled that before running ai tests...
User avatar
jcnossen
Former Engine Dev
Posts: 2440
Joined: 05 Jun 2005, 19:13

Post by jcnossen »

Better crash reporting resulted in worse AI debugging, I didn't really think about that :oops:

Compile spring with NO_CATCH_EXCEPTIONS defined (and disable catching AI exceptions) and it should let all exceptions through.

I can't put an executable like that online though, since I don't have my development stuff connected to the internet atm.
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Post by AF »

Actually, I'm quite happy with debugging now.

I got my debug builds to compile with debug data again after i broke ti during XE9RC14, and now I get nice dialog boxes from spring saying exactly what happened and the cause and where asking if I wanna ignore debug or exit, and then i can carry on or go into the debugger from there.


In fact ti saved me hassle as exceptions in the newly ported TDFParser where being caught by spring even though it was a release build, and it was displaying message boxes.


However a spring related issue.

The debugger shows sometimes spring has an exception thrown. In the event of a re throw spring catches it again and exits, but ti does so without warning, no crash dialogs or error reports not even a message box, which can be very disconcerting tot h user.
submarine
AI Developer
Posts: 834
Joined: 31 Jan 2005, 20:04

Post by submarine »

could someone provide me with an spring.exe without any error catching? i cant compile myself, since 0.72 i get lots of linker errors...

edit: ok cleaning the proj files and manually adding all source files solved the problem, it seems somebody forgot to update the proj files when adding files...
Post Reply

Return to “AI”