Walkback

 


 

A Walkback is the standard way in which "errors" are displayed by Dolphin Smalltalk. A common example is a "Message not understood" walkback, which occurs when an attempt is made to send a message to an object which does not provide an implementation for a particular message.

It won't be very long before you see a Walkback (all of us make at least an occasional typo) but when you do, don't panic. It is rarely fatal, and not as complicated as it first appears. Even when Dolphin displays Walkbacks for situations which will crash traditional programming environments (e.g. General Protection Faults), you can normally just press the terminate button and continue working. As you become more familiar with the system, you will begin to use the Walkback to launch into debugging sessions.

The Walback dialog consists of a Stack Trace pane, a severity icon, and four buttons, Debug, Resume, Terminate, and Kill.

The title of the Walkback dialog is a short, and hopefully helpful, description of the error. Sometimes this description alone is sufficient to resolve the problem (e.g. a typo in a message name).

The Stack Trace pane displays a short description of each method or block activation (stack frame) pending return in the process stack. The stack is displayed to a predetermined maximum depth but, if required, the entire stack can be seen in the debugger. Each stack frame description identifies the method being executed and the class implementing the method (if this is different). You can scroll through this list using the cursor keys.

Tip: if you see a Walkback which you believe indicates a problem with Dolphin (rather than one of your own programming errors) then it can be useful to select and copy the entire contents of the Stack Trace pane. You can then paste this information into a bug report and mail it to Object Arts or the support newsgroup.

The severity icon uses the familiar Windows message box graphics to indicate the severity of the event that generated the Walkback. Usually this will be the Error icon, meaning a non-resumable error has been encountered. In this case the Resume button will be disabled. If a Warning icon is displayed, then the event was not fatal (e.g. an assertion failure), and you can attempt to continue by pressing the Resume button. When Resume is pressed the process will continue from where it left off. Do not be surprised, however, if further Walkbacks then occur.

The Terminate button dismisses the Walkback, and cleanly terminates the process in which the error event occurred. You can then continue working as normal.

The Kill button is a last resort to be used when pressing the Terminate button produces a further Walkback.

Tip: because this is a slightly unsafe operation, you will be asked to confirm that you really want to kill the process. Sometimes even this will not work, and you will get additional Walkbacks. If this happens try the "Panic" button in the Transcript's toolbar. If you still cannot get rid of the problem then exit Dolphin, but do not save the image as it may have been corrupted by the error. Occasionally, in dire situations, you may need to use the operating system Task Manager to kill the Dolphin process.

The remaining button, Debug, is the most interesting because it invokes the Debugger so that you can investigate the error further. In fact, the normal way to open a Debugger is by sending the #halt message to an object (either by evaluating an expression containing the message, or by compiling it into a method).

Tip: If ever the system appears to be locked up it may be executing a continuous loop in Smalltalk code. Presings Ctrl+Break, should bring up a "User Interrupt" Walkback so that you can then enter the Debugger and see what is happening.