You are not logged in.
I am some weeks into life after re-building my computer and upgrading to BunsenLab. Tweaking is mostly over but there are some issues left. Like this one.
Writing Python code is something I mostly do in Geany and I am used to hit F5 to run my code. Not so in BL it seems. I have tried editing set-ups (use terminator and /bin/bash please) but there is no shift in behaviour. All I get is an error message telling me that no shell could be found. The error message appears in a freshly opened instance of terminator.
Anyone know what may be the matter?
Could it be that I have made the BL installation use my native Swedish as the 'system' language (it even confuses me)?
TIA
/Martin
Last edited by Martin (2016-02-20 17:16:55)
"Problems worthy of attack
prove their worth by hitting back."
Piet Hein
Offline
shell means python shell i suppose.
have you checked what geany is actually looking for there? maybe you're missing some optional dependencies.
Offline
Geany has the Run/Execute keybind as F5, as expected. In the "Set Build Commands" dialog, "Execute" is set as "./%f", which implies to me that the python file needs to be executable.
You could also try editing the Execute command, maybe try "python %f"
Be Excellent to Each Other...
The Bunsenlabs Lithium Desktop » Here
FORUM RULES and posting guidelines «» Help page for forum post formatting
Artwork on DeviantArt «» BunsenLabs on DeviantArt
Offline
Geany has the Run/Execute keybind as F5, as expected. In the "Set Build Commands" dialog, "Execute" is set as "./%f", which implies to me that the python file needs to be executable.
Also, it needs to have a shebang at top:
#!/usr/bin/env python3
etc.
Offline
Thanks guys.
I have looked into all of your suggestions -- to no avail :-(
If I open the code in emacs I have no problems running it from inside emacs so it's not like I don't have options but since I am not a seasoned Python coder I appreciate the extra help I get from Geany.
/Martin
"Problems worthy of attack
prove their worth by hitting back."
Piet Hein
Offline
See this post on crunchbang by damo
In layman terms:
when x-terminal-emulator is set to terminator in stead of xterm (which is the geany default), then geany needs to be patched to use --command in stead of -e.
@OP: if you absolutely want to use geany to launch your python scripts, then you should set x-terminal-emulator to xterm in stead of terminator.
Thanks for reporting this.
I suggest that we patch geany so that it works with terminator set as x-terminal-emulator instead of xterm. Perhaps we can even make it work no matter which emulator is set x-terminal-emulator.
After closer scrutiny the problem is with using terminator as x-terminal-emulator.
Terminator does not split the arguments of the spawned command on whitespace. xterm does.
The problem is there on a Debian stable install as well when using terminator as x-terminal-emulator.
Offline
Bingo!
"--command" instead of "-e" was what I needed.
/Martin
"Problems worthy of attack
prove their worth by hitting back."
Piet Hein
Offline