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

Home » Public Forums » archive » Re: Locked-up workbench: ctrl-C doesnt work
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: Locked-up workbench: ctrl-C doesnt work [message #59507] Fri, 28 March 2008 09:03
R.G. Stockwell is currently offline  R.G. Stockwell
Messages: 363
Registered: July 1999
Senior Member
"elwood" <epolomsk@uwsp.edu> wrote in message
news:6e6ba6f7-5c0e-4783-a79c-2f329e2686ee@i7g2000prf.googleg roups.com...
> On Mar 27, 11:15 pm, David Fanning <n...@dfanning.com> wrote:
...
> I'm reasonably sure its not an infinite loop
> because I had one guy add bunches of print statements,
> including some that were placed prior to any of his loops,
> immediately after the program started.


you may have to flush the prints.


Put in some stops. (at the beginning of the program,
since you seem to think it doesn't even start going,
and before and after the loop)

You could put a if counter gt 1000 then stop
inside the loop to see if you reach it (choose an appropriate number)

And print out a counter in the loop.


Cheers,
bob
Re: Locked-up workbench: ctrl-C doesnt work [message #59513 is a reply to message #59507] Thu, 27 March 2008 22:40 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
elwood writes:

> My one and only clue is that he did have some accumulated syntax
> errors at one point
> and had not run retall.
> He just kept editing and re-executing his program until everything
> completely locked up.

I suppose it's possible to get so far down into the bowels of
a program there is no way back to the top. I think I would
try adding ON_ERROR, 2, at least. No sense letting people
stew in their ignorance. :-)

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
Re: Locked-up workbench: ctrl-C doesnt work [message #59514 is a reply to message #59513] Thu, 27 March 2008 21:51 Go to previous message
elwood is currently offline  elwood
Messages: 23
Registered: February 2007
Junior Member
On Mar 27, 11:15 pm, David Fanning <n...@dfanning.com> wrote:
> elwood writes:
>> More than half a dozen times today my students managed to
>> irretrievably hang the IDL workbench.
>> They were running a while loop within their program.
>> No syntax error was issued, but when they ran the program it would not
>> execute.
>> And the idl command-line prompt went grey.
>
>> ctrl-c did not get them out of this state
>> reset perspective did not get them out of this locked-up state
>
>> I wish I could give you more hints, but its unclear what is causing
>> this problem.
>> It is not an infinite loop.
>
> How do you know? That's what it sounds like to me. See below.
>
>> Out of desperation they killed the workbench entirely by clicking on
>> the little close x for the window.
>> And then went to Windows XP task manager and killed the idl task.
>
>> Has anyone else noted this problem?
>> Is there another method of getting IDL out of a locked-up state?
>
> I'm no huge fan of the Workbench, but this sounds strange.
> Honestly, it sounds more like bad CATCH error handling to me. Does
> everyone have a CATCH, /CANCEL as the first line of their
> CATCH error handler?
>
> I've taught several classes on the Workbench, and I haven't
> run into problems like this, although one guy was rebooting
> all the time. He never let me see the reason for that, so
> I assume it was something he was doing, not IDL.
>
> Cheers,
>
> David
> --
> David Fanning, Ph.D.
> Fanning Software Consulting, Inc.
> Coyote's Guide to IDL Programming (www.dfanning.com)
> Sepore ma de ni thui. ("Perhaps thou speakest truth.")

I'm reasonably sure its not an infinite loop
because I had one guy add bunches of print statements,
including some that were placed prior to any of his loops,
immediately after the program started.
None of them would print or execute.
The last guy who had this problem did not have any error catching
statements in his program.
That was one of my first suspicions as well!
Perhaps I should in fact have them ADD in some error handling to see
if catches what ever
is causing this problem.

It has never happened to me personally either!

My one and only clue is that he did have some accumulated syntax
errors at one point
and had not run retall.
He just kept editing and re-executing his program until everything
completely locked up.
Re: Locked-up workbench: ctrl-C doesnt work [message #59515 is a reply to message #59514] Thu, 27 March 2008 21:15 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
elwood writes:

> More than half a dozen times today my students managed to
> irretrievably hang the IDL workbench.
> They were running a while loop within their program.
> No syntax error was issued, but when they ran the program it would not
> execute.
> And the idl command-line prompt went grey.
>
> ctrl-c did not get them out of this state
> reset perspective did not get them out of this locked-up state
>
> I wish I could give you more hints, but its unclear what is causing
> this problem.
> It is not an infinite loop.

How do you know? That's what it sounds like to me. See below.

> Out of desperation they killed the workbench entirely by clicking on
> the little close x for the window.
> And then went to Windows XP task manager and killed the idl task.
>
> Has anyone else noted this problem?
> Is there another method of getting IDL out of a locked-up state?

I'm no huge fan of the Workbench, but this sounds strange.
Honestly, it sounds more like bad CATCH error handling to me. Does
everyone have a CATCH, /CANCEL as the first line of their
CATCH error handler?

I've taught several classes on the Workbench, and I haven't
run into problems like this, although one guy was rebooting
all the time. He never let me see the reason for that, so
I assume it was something he was doing, not IDL.

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming (www.dfanning.com)
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Need GOES Image Expert
Next Topic: (simple question) PLOT, YTICKS in /YLOG AXIS

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

Current Time: Fri Oct 10 07:44:30 PDT 2025

Total time taken to generate the page: 1.35668 seconds