#852 After interrupting a python script with ctrl+c the F5 Button no longer works

open
nobody
General (289)
5
2012-04-15
2012-04-15
No

geany 0.21 (kompiliert am Mar 19 2012 mitGTK 2.24.10, GLib 2.31.20) on Ubuntu 12.04 (Beta2)

To reproduce:

- start a python script by pressing F5 (strat script enabled) in VTE
- interrupt the script by pressing ctrl-c
- script will stop, prompt will appear
- press F5, to start the script again => nothing will happen
- start the script with the help of the Menu (create -- execute F5) => script will be executed normaly

So I think the problem is not in the VTE but in the way Geany handles the F5 Button.

Discussion

  • Lex Trotman

    Lex Trotman - 2012-04-16

    The problem is that VTE has the focus when you typed ctrl-c so when you try to run the second time, so the F5 key never gets to Geany to run the command, it is eaten by VTE.

     
  • Felix Haller

    Felix Haller - 2012-04-16

    No. After executing and canceling the script I have clicked into the editor area so that the VTE lost the focus. Therefore I think the F5 is not eaten by the VTE.

     
  • Enrico Tröger

    Enrico Tröger - 2012-04-16

    The F5 key press in not eaten by anyone, indeed.
    But you should see a message like 'Could not execute the file in the VTE because it probably contains a command.' in the status bar (and in Help>Debug Messages).
    This is some kind of auto protection in Geany to not automatically insert text into the VTE and execute it (imagine someone typed 'rm -rf / && ' and then Geany would append '/bin/sh ...' and send a Return signal). However, it seems the Ctrl-C is not detected as a clean command although it should be. It might be that this depends on the 'Override Geany keybindings' VTE preference.

     
  • Felix Haller

    Felix Haller - 2012-04-16

    I know this message and also know about its advantages but it's not displayed in this case. I can also press return a couple of times, to remove any command maybe allready given to the prompt but when I press F5 nothing happens.
    I tested it again on geany 0.21 (Gromia compiled 10 Dec 2011) and there it works perfectly. Maybe something has changed in the vte in precise?

     
  • Lex Trotman

    Lex Trotman - 2012-04-17

    Latest Git head, status is:

    1. pressing F5 anytime the VTE has focus will not work, no error message

    2. pressing F5 with focus on the edit window anytime the VTE is unclean will not work, with the error message

    3. pressing return or ctrl-c several times cleans the VTE and allows F5 to work if the focus is returned to the edit window first

    4. pressing F5 when VTE has the focus not only doesn't work, it makes it unclean, so it will no longer work when the edit window has focus.

    The original post noted that F5 did not work, but the menu did, since F5 just activates the menu the only difference is that selecting the menu doesn't care what the focus was.

     
  • Felix Haller

    Felix Haller - 2012-04-18

    i have to say that the test with the older build of 0.21 mentioned in my last post was done on oneiric. Therefore my assumption that something has changed in precise.

     
  • Lex Trotman

    Lex Trotman - 2012-04-19

    Maybe its a VTE version thing.

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks