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: InterpreterSeverity: 3 - Normal
Priority: 2Item Group: Matlab Compatibility
Status: FixedAssigned to: None
Originator Name: Richard CrozierOpen/Closed: Closed
Release: devOperating 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 Jump to the original submission)

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

This should be fixed by changeset


Lachlan Andrew <lachlan>
Project Member
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 File(s):

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


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

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

    Only project members can vote.


    Please enter the title of George Orwell's famous dystopian book (it's a date):



    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue 16 Feb 2016 02:02:17 AM UTCrik5Open/ClosedOpen=>Closed
    Mon 08 Feb 2016 05:53:40 AM UTClachlanStatusNone=>Fixed
    Fri 22 May 2015 03:05:50 PM UTCrik5SummaryHitting 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)
    Fri 22 May 2015 03:05:49 PM UTCrik5Priority5 - Normal=>2

    Back to the top

    Powered by Savane 3.1-cleanup1