bugGNU Octave - Bugs: bug #51349, debug mode, when entered from a...


bug #51349: debug mode, when entered from a batch mode script, has readline disabled

Submitter:  CarnĂ« Draug <carandraug>
Submitted:  Fri 30 Jun 2017 01:54:35 PM UTC
Category:  Interpreter Severity:  3 - Normal
Priority:  3 - Low Item Group:  None
Status:  Confirmed Assigned to:  None
Originator Name:  Open/Closed:  * Open
Release:  * dev Operating System:  * GNU/Linux
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment (Rich Markup)

Comment Type & Canned Response:


Fri 30 Jun 2017 09:22:57 PM UTC, comment #1: 

Confirmed.  There is an easy enough workaround which is to start an interactive session of Octave and then run the script file to be debugged from the Command Window (GUI) or command line (CLI).

The issue is that when running a script directly from the shell command line Octave believes it is being called in non-interactive batch mode.  This would be common if you were running an already debugged script to analyze a new dataset.  If Octave is running non-interactively, it believes it doesn't need line-editing capabilities supplied by Readline.  Hence the behavior you are seeing.

Another workaround would be to use the command-line option "--line-editing" which will force Octave to include Readline behavior.

Rik <rik5>
Project Administrator
Fri 30 Jun 2017 01:54:35 PM UTC, original submission:  

When an Octave program enters in debug mode, readline is disabled.  Command history is not available, arrows to edit a command are not available, Ctr+C exits instead of cancelling command.  This worked in Octave 3.8 (seems to be broken since 4.0).

To reproduce:

1. Have a file with just the command "keyboard"
2. Run 'octave that-file.m'
3. Try to use tab to autocomplete a command name. Write a command and then use the left arrow to edit any character without backspace.

Carnë Draug <carandraug>
Project Member


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

Attach Files:

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 rik5 (Posted a comment)
  • -email is unavailable- added by carandraug (Submitted the item)

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only project members can vote.





    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-06-30 rik5 Summarydebug mode from a program has readline disabled debug mode, when entered from a batch mode script, has readline disabled
    2017-06-30 rik5 Priority5 - Normal 3 - Low
        StatusNone Confirmed

    Back to the top

    Powered by Savane 3.10