bugGNU Octave - Bugs: bug #37576, Make "dbstop if error"...

 
 

bug #37576: Make "dbstop if error" equivalent to debug_on_error(1) and debug_on_interrupt(1)

Submitted by:  Richard <crobar>
Submitted on:  Mon 15 Oct 2012 10:39:44 AM UTC  
 
Category:  Interpreter Severity:  3 - Normal
Priority:  2 Item Group:  Matlab Compatibility
Status:  Fixed Assigned to:  None
Originator Name:  Richard Crozier Open/Closed:  Closed
Release:  dev Operating System:  GNU/Linux

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

( Jump to the original submission)

Mon 08 Feb 2016 05:53:40 AM UTC, comment #6:

This should be fixed by changeset

http://hg.savannah.gnu.org/hgweb/octave/rev/94fc5f13d51b

Lachlan Andrew <lachlan>
Fri 22 May 2015 03:05:50 PM UTC, comment #5:

Re-titled to reflect the true issue. Lowered the priority since there is an easy workaround.

Rik <rik5>
Project Administrator
Thu 01 Nov 2012 03:46:36 AM UTC, comment #4:

I added seealso links between the debug_on_error function and the debug_on_warning and debug_on_interrupt functions. For the time being, I hope that will be enough to point people in the right direction.

Rik <rik5>
Project Administrator
Mon 15 Oct 2012 07:07:10 PM UTC, comment #3:

For compatibility, I suppose we should consider making "dbstop if error" equivalent to setting both debug_on_error and debug_on_interrupt to true. I have to say that seems weird because Ctrl-C is not really an error. But whatever, we do a lot of other strange things in the name of compatibility.

John W. Eaton <jwe>
Project Administrator
Mon 15 Oct 2012 06:51:16 PM UTC, comment #2:

I haven't tried, but I'm sure it will, sorry for the noise, I wasn't aware of this function.

Richard <crobar>
Mon 15 Oct 2012 06:48:45 PM UTC, comment #1:

Octave also has a 'debug_on_interrupt' function. Does that work for you?

John W. Eaton <jwe>
Project Administrator
Mon 15 Oct 2012 10:39:44 AM UTC, original submission:

In matlab, when you hit CTRL+C with the equivalent of debug_on_error set to true (in matlab this is set by "dbstop if error") matlab drops into debug mode at the currently executing line.

In contrast Octave simply quits execution of whatever is currently running and returns to the octave command prompt.

This functionality can be useful in various situation, e.g. locating endless loops in code which does not always exhibit the behaviour, and tracking down difficult to reproduce bugs, and examining the contents of variables when they occur.

Richard <crobar>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by lachlan (Posted a comment)
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by jwe (Posted a comment)
  • -email is unavailable- added by crobar (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

     

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-02-16 rik5 Open/ClosedOpen => Closed
    2016-02-08 lachlan StatusNone => Fixed
    2015-05-22 rik5 SummaryHitting CTRL+C with debug_on_error(1) does not go into debug mode, does in ML => Make "dbstop if error" equivalent to debug_on_error(1) and debug_on_interrupt(1)
    2015-05-22 rik5 Priority5 - Normal => 2

    Back to the top


    Powered by Savane 3.3