bugGNU Octave - Bugs: bug #42309, debug mode continues when file is...

 
 

bug #42309: debug mode continues when file is run from GUI editor

Submitted by:  Ceral Paquet <octavebugs>
Submitted on:  Tue 06 May 2014 05:22:13 PM UTC  
 
Category: GUISeverity: 3 - Normal
Priority: 5 - NormalItem Group: Incorrect Result
Status: FixedAssigned to: None
Originator Name: Open/Closed: Closed
Release: 3.8.1Operating 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)

Thu 12 Jun 2014 05:52:07 PM UTC, comment #6:

I have pushed the changeset
http://hg.savannah.gnu.org/hgweb/octave/rev/4b98fc5c2eb1
(gui-release branch) which fixes the bug for me. If this is also successful on your system I will close the bug report.

Should the patch be applied to the stable branch instead?

Torsten <ttl>
Project Member
Thu 05 Jun 2014 01:26:12 PM UTC, comment #5:

This is the same issue as described in bug #38983 which was closed since the bug was not reproducible in on the development branch anymore. I tested it yesterday and it does appear in all branches.

The patch for bug #38983 still fixes the issue (file #29400) but I am still not sure what side effect may be introduced by

instead of

Torsten <ttl>
Project Member
Thu 05 Jun 2014 01:42:10 AM UTC, comment #4:

The same error holds for breakpoints set from the command line with dbstop or set graphically in the GUI editor.

Mike Miller <mtmiller>
Project Administrator
Wed 07 May 2014 05:09:13 PM UTC, comment #3:

Thanks Torsten. I was looking at the main_window code, not carefully enough, and misunderstood what it was doing there. It only does "run testfunc" if the command can't be called directly by its own name (after prompting), that makes sense.

So I can confirm this with both 3.8.1 and (recent but not current) gui-release.

Mike Miller <mtmiller>
Project Administrator
Wed 07 May 2014 04:30:31 PM UTC, comment #2:

Executing a file (e.g. testfunc.m) from the editor actually calls the script "testfunc" instead of running it with "run testfunc".

Torsten <ttl>
Project Member
Wed 07 May 2014 01:40:10 PM UTC, comment #1:

Thanks for your bug report. This is a bit confusing. Is the m-file testme a script or a function file? Does it contain the definition of a function or does it execute the function? Or both? When I create a file testfunc.m with:

and call testfunc from the command prompt, it works correctly. If I try to "execute" it using "run" or "source", it does nothing (as expected). If I "execute" it from the editor, yes I see what you are seeing.

I suspect that this should do nothing, because "executing" a file that contains nothing but a function definition should just drop back to the shell. So it does seem like a bug that running it from the GUI does something different from "run testfunc" at the command line.

Mike Miller <mtmiller>
Project Administrator
Tue 06 May 2014 05:22:13 PM UTC, original submission:

When I run this script using the GUI button "Save File and Run" then it correctly stops at the keyboard command. However if I subsequently enter anything at the command line then the program continues (i.e. exits debug mode). The same behavior doesn't occur when calling testme() from the command line.

function testme()

disp('test')

keyboard

disp('hello')

This is the output in the command window when running the program from the GUI:

>> testme

test
stopped in /home/ceralpaquet/octave/testme.m at line 5
5: keyboard
debug> a=1
hello

>>


Ceral Paquet <octavebugs>

 

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

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Digest:
   bug dependencies.

 

Carbon-Copy List
  • -unavailable- added by ttl (Posted a comment)
  • -unavailable- added by mtmiller (Posted a comment)
  • -unavailable- added by octavebugs (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 9 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 20 Jul 2014 05:36:36 PM UTCttlStatusReady For Test=>Fixed
      Open/ClosedOpen=>Closed
    Thu 12 Jun 2014 05:52:07 PM UTCttlStatusConfirmed=>Ready For Test
    Thu 05 Jun 2014 01:43:59 AM UTCmtmillerDependencies-=>bugs #42506 is dependent
    Thu 05 Jun 2014 01:42:10 AM UTCmtmillerSummarykeyboard (debug mode) not quite right when running from GUI=>debug mode continues when file is run from GUI editor
    Wed 07 May 2014 05:09:13 PM UTCmtmillerStatusNeed Info=>Confirmed
    Wed 07 May 2014 01:40:10 PM UTCmtmillerCategoryNone=>GUI
      Item GroupNone=>Incorrect Result
      StatusNone=>Need Info

    Back to the top


    Powered by Savane 3.1-cleanup1