comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Almost dead widgets
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: Almost dead widgets [message #19991] Mon, 15 May 2000 00:00
promashkin is currently offline  promashkin
Messages: 169
Registered: December 1999
Senior Member
Ben Tupper wrote:
> also it heals! I'm gonna tape a copy of it on the inside of the hood of my
> car!

Ben, try also to hang a v. 5.3 CD-ROM on your rear-view mirror. I am
afraid that "decomposed=0" ain't gonna help the car; mine really is
"decomposed" though :-)

Cheers,
Pavel
Re: Almost dead widgets [message #19992 is a reply to message #19991] Mon, 15 May 2000 00:00 Go to previous message
Ben Tupper is currently offline  Ben Tupper
Messages: 186
Registered: August 1999
Senior Member
Ben Tupper wrote:

> I have a blocking widget application that calls a modal widget
> application. Carefully planted bugs (not planted by me, of course) in
> the second application crash the application. I can clean up the
> second (crashed) widget but not the first. Even the system control
> button with 'QUIT' doesn't quite do it. It is, as David F describes,
> almost dead but not entirely dead. So far, my solution involves brute
> force and ignorance, which works but is messy: I ignore the widget
> carnage until my desktop looks like a checkerboard, then I exit IDL when
> no one can see what I'm doing. I have never bumped into this before,
> so I'm not sure what I've done to cause this mess. I'm not even sure
> what info would be helpful to identifiy the problem. Any suggestions
> greatly appreciated.
>
>

Hello,

Thanks to all for the help. I discovered what may be the problem. In the
first routine's cleanup procedure, I failed to check for the existence of
top level base's info structure before trying to free the pointers it
contained. I can't say I understand why the widget is not destroyed
(completely dead) by WIDGET_CONTROL, Even.Top, /Destroy before XMANAGER
calls my cleanup procedure, but maybe I don't need to.

It took me a while to figure this out for two reasons; (1) I didn't (and
haven't before) done any error checking in my cleanup routine and (2) I
couldn't get the problem to happen again (until just now).

At first, I was really wowed by David's ERROR_MESSAGE because after I
sprinkled it throughout the routines, I couldn't get the problem to occur
again. Geez, that's good software: not only does it report diagnostics but
also it heals! I'm gonna tape a copy of it on the inside of the hood of my
car!

Ben


--
Ben Tupper

Bigelow Laboratory for Ocean Science
tupper@seadas.bigelow.org

pemaquidriver@tidewater.net
Re: Almost dead widgets [message #20058 is a reply to message #19991] Thu, 11 May 2000 00:00 Go to previous message
Dominic Zarro is currently offline  Dominic Zarro
Messages: 7
Registered: July 1998
Junior Member
widget_control,/reset,/clear_events,bad_id=destroyed

The above command is usually guaranteed to kill
any zombie widgets.
Re: Almost dead widgets [message #20062 is a reply to message #20058] Wed, 10 May 2000 00:00 Go to previous message
promashkin is currently offline  promashkin
Messages: 169
Registered: December 1999
Senior Member
I ran into something like that. Even not having access to command line,
I noticed that the RUN menu was still accessible for mousing around,
even while stuck in an infinite loop (I use a Mac). Then, often I could
select Reset there, which would kill all widgets, heap variables and
everything else that was left there unattended.
Cheers,
Pavel

Ben Tupper wrote:
>
> No, I don't have access to the command line until AFTER I manually interrupt
> immediately after the crash. Because I must manually
> interrupt, does that mean that I'm in an unfinshed event loop??
Re: Almost dead widgets [message #20068 is a reply to message #20062] Wed, 10 May 2000 00:00 Go to previous message
Ben Tupper is currently offline  Ben Tupper
Messages: 186
Registered: August 1999
Senior Member
David Fanning wrote:

>
> Humm. I'm not sure *where* you are. But I'm pretty
> sure it's a bad neighborhood. I'm afraid the only thing
> for it is to track down the source of your problem or
> add some bulletproof CATCH error handlers. If you use
> my Error_Message program with the TRACEBACK keyword set
> in your CATCH error handler you can both get a traceback
> of the error *and* keep the program running. That would be
> an improvement on your current situation, I think. :-)
>

I know where I am: lost! The trickier part is getting unlost.

I'll try the Error_Message... I have used it before but I was hurrying this
time. Haste makes waste.

Thanks,

Ben

--
Ben Tupper

Bigelow Laboratory for Ocean Science
tupper@seadas.bigelow.org

pemaquidriver@tidewater.net
Re: Almost dead widgets [message #20069 is a reply to message #20062] Wed, 10 May 2000 00:00 Go to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Ben Tupper (tupper@seadas.bigelow.org) writes:

> No, I don't have access to the command line until AFTER I manually interrupt
> immediately after the crash. Because I must manually
> interrupt, does that mean that I'm in an unfinshed event loop?

Humm. I'm not sure *where* you are. But I'm pretty
sure it's a bad neighborhood. I'm afraid the only thing
for it is to track down the source of your problem or
add some bulletproof CATCH error handlers. If you use
my Error_Message program with the TRACEBACK keyword set
in your CATCH error handler you can both get a traceback
of the error *and* keep the program running. That would be
an improvement on your current situation, I think. :-)

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
Re: Almost dead widgets [message #20070 is a reply to message #20062] Wed, 10 May 2000 00:00 Go to previous message
Ben Tupper is currently offline  Ben Tupper
Messages: 186
Registered: August 1999
Senior Member
David Fanning wrote:

> Do you have access to the IDL command line when everything
> goes to hell in a handbasket? If so, have you tried typing
> Widget_Control, /Reset?

No, I don't have access to the command line until AFTER I manually interrupt
immediately after the crash. Because I must manually
interrupt, does that mean that I'm in an unfinshed event loop?

> But that "checkerboard" thing makes
> me think the window manager is corrupted somehow. I'd try
> a .Reset_Session, just for grins, before I reached for that
> IDL Quit button, but that may be your own recourse.
>

Just to be clear, I can minimize these windows after the crash... hence the
checkerboard of 'dead' icons.
Unfortunately, I can't use .reset_session because I'm in IDL v5.2
IDL> help, !Version,/Str
** Structure !VERSION, 5 tags, length=40:
ARCH STRING 'sparc'
OS STRING 'sunos'
OS_FAMILY STRING 'unix'
RELEASE STRING '5.2'
BUILD_DATE STRING 'Oct 30 1998'



Ben


--
Ben Tupper

Bigelow Laboratory for Ocean Science
tupper@seadas.bigelow.org

pemaquidriver@tidewater.net
Re: Almost dead widgets [message #20071 is a reply to message #20062] Wed, 10 May 2000 00:00 Go to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Ben Tupper (tupper@seadas.bigelow.org) writes:

> I have an embarassing problem... I can't seem to sweep this one into the
> dustbin.

I'm looking into how to get this Kill File thingy working on
my news reader. Let's see, "Ben Tupper + problem"... :-)

> I have a blocking widget application that calls a modal widget
> application. Carefully planted bugs (not planted by me, of course) in
> the second application crash the application. I can clean up the
> second (crashed) widget but not the first. Even the system control
> button with 'QUIT' doesn't quite do it. It is, as David F describes,
> almost dead but not entirely dead. So far, my solution involves brute
> force and ignorance, which works but is messy: I ignore the widget
> carnage until my desktop looks like a checkerboard, then I exit IDL when
> no one can see what I'm doing. I have never bumped into this before,
> so I'm not sure what I've done to cause this mess. I'm not even sure
> what info would be helpful to identifiy the problem. Any suggestions
> greatly appreciated.

Oh, my Gosh. :-(

Do you have access to the IDL command line when everything
goes to hell in a handbasket? If so, have you tried typing
Widget_Control, /Reset? But that "checkerboard" thing makes
me think the window manager is corrupted somehow. I'd try
a .Reset_Session, just for grins, before I reached for that
IDL Quit button, but that may be your own recourse.

But I'm becoming intimately familiar with the Control-Alt-Delete
buttons this morning myself, as I can't figure out where this
infinite loop is coming from. :-(

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Object Data and pointer assignments
Next Topic: Re: Plot bug or another "strange feature" ?

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 13:31:27 PDT 2025

Total time taken to generate the page: 0.00843 seconds