wyverniv
wyverniv

Reputation: 289

octave 3.8.1 can't stop execution in gui command window

I'm running octave 3.8 with the gui in Ubuntu 14.04. I have an infinite loop somewhere in my program and it seems like the terminal doesn't respond to the typical keypresses to stop execution. (eg. Ctrl+C, Ctrl+Z) When I run programs in the terminal, I can just press Ctrl+C, but that doesn't seem to work here. What can I do to halt execution?

Upvotes: 18

Views: 39741

Answers (4)

user23548925
user23548925

Reputation: 1

I successfully tried using the system monitor to stop the process of octave, and of octave-gui. octave and octave-gui processes are available in the system monitor.

After stopping the process, when I clicked on the octave gui, it brought a complaint to terminate or wait. I ignored that and went to the system monitor, and I told it to continue the octave-gui process (only). (Telling it to continue the octave process did not help.) Then, I returned to the gui by clicking on the command window. I pressed control+c immediately. Now, depending on how many times I had pressed run/f5, and on how "hard" it was hanging, I had to stop the octave-gui and octave processes again, by using the system monitor, then, continue the octave-gui process, and press ctrl+c, until I had applied ctrl+c on each run. Sometimes, it was enough to use the system monitor once, and then use only ctrl+c several times.

(The type of hang unending looping trouble I solved and replicated and solved was:

I had an algorithm that hangs, running without stopping, when a number was less than another one, because I did not put that test as its stop condition. So, when I ran it, I thought it finished because no extra output came out on the command window. But it was still running. I had continued to type. Then I ran my program again, and "nothing happened". I ran it again, thinking that I miss pressed something. I got nothing. Then, I noticed that it did not finish the first run. Then I applied the procedure I gave above.

This was how I replicated and solved the unending looping problem.)

Upvotes: 0

Abhijit_STACK
Abhijit_STACK

Reputation: 11

after going through lots of bugs report and all.

Finally by hitting (ctr + c + Enter) at command window (below the pause statment) execution gets terminated.

hope it works for u too.

Upvotes: 1

Alabi Temitope
Alabi Temitope

Reputation: 468

To stop a running command or script in octave GUI or prompt:

  1. Ctrl+C

you will see:

less -- (f)orward, (b)ack, (q)uit

To abort (and close the GUI or command line):

  1. Control+C

To just stop printing the output of the command or script (?):

  1. q
  2. Enter

Upvotes: 11

Alexander Solovets
Alexander Solovets

Reputation: 2507

It's a long-running bug that hasn't been fixed since 2012, run with --no-gui if possible.

Upvotes: 2

Related Questions