How do I run a .py module in Aptana? - eclipse

Every time I try to run a .py module it just opens in Firefox.
I'm running Aptana in OS X 10.6

If you installed and configured PyDev, it should work.
Make sure you use the correct "Run" command. Prefer "Run as Python module", avoid "Run on Server".
If that doesn't help, edit your question and give an exact example what you do (which menus/buttons you click, etc).

See: http://pydev.org/manual_101_run.html for details on running a Python module (make sure you read the whole getting started: http://pydev.org/manual_101_root.html which should help you in getting your environment setup and gives some tips to properly use PyDev).

I used a same workspace for both python and java , and met the same problem.
If I change a new workspace, the Run As works. So i think there is something wrong with workspace settings.

Related

Python module will not run correctly from command prompt

This goes out to anyone who is well versed in the Eclipse IDE and or PyDev perspective plug-in who is willing to offer some technical support.
I am trying to write a python module that must take in arguments from the command prompt with sys.argv function calls. Rather than printing out the correct output when I enter E:\ ... \src>program.py arg1 arg2, all that happens is a new command line (E:\ ... \src>) is output and the Eclipse IDE window flashes orange without any code in my python module actually being executed. Also, if I close the Eclipse IDE and try to run program.py, it will just open Eclipse again and open my program in a new tab.
I'm confused as to why it is not working now when just last week it was working perfectly while testing another program that took in arguments from the command prompt by sys.argv function calls. My question for everyone is whether or not you are aware of any settings that may have been altered by updates, etc. that could cause this problem; or has anybody out there ever run into this problem and figured out how to resolve it? I have already checked my PATH variable, so that is not the problem :-(. Any help you can provide would be greatly appreciated ... thank you.
OS: Windows 8.1 Pro / Eclipse ver.: Kepler (4.3) / Python ver.: 3.3.2
I answered my own question in the comment above. I just had to wait to post an answer due to the fact that I just created a stackoverflow account yesterday.

Eclipse LDT doesn't run local Lua interpreter

I have problem with Eclipse LDT. When I run my test Lua app, it executes just fine using JNLua inside JavaVM environment. But according to this tutorial, when I reference native lua.exe interpreter and set it in Run Configuration as Runtime Interpreter, Run Configuration disables Launch script: and nothing is executed. When I run a same script with a same native local Lua interpreter 5.1, everything works just fine.
So, what is the problem with LDT? Has anyone had the same experience?
EDIT
I've managed to run local lua.exe from Lua Development Tools stand-alone product, but still it doesn't work as Eclipse plug-in.
I'm not sure it's a bug.
I guess when you register your interpreter, you uncheck the checkbox : "Accept file as argument"
This mean LDT will not manage the file to launch (that's why the Launch script is disabled)
The standard lua interpreter support file as argument and -e option, so the two check box should be checked. (It's the default value)
It looks like a bug ... Would you mind filing it in the Koneki bug tracker?

How can I create a make file using Plugin builder with QGIS?

I am using the plugin "plugin builder" to generate a template. The plugin builder is also generating a make file. I am working on a computer using windows 7 and am trying to execute the make file using the command line of Windows (MS Dos). However, this doesen't work. This means that my *.ui and my *.qrc file are not compiled to python, if I understand correctly.
What can I do? I am not very familiar with pc or programming so I hope to finde someone who can give me an easy understandable answer. Thank you.
Run the code in the osgeo4w Shell
And follow the steps in here:
http://www.qgisworkshop.org/html/workshop/plugins_tutorial.html
If the osgeo4w shell doesn't work copy the qtcore4.dll and qtgui4.dll to the windows system directory first
Regards
'make', works in linux by default as it is part of its build system. For windows, you could try downloading GNU Make Setup from below link
GNU make link
afterwards, you should be able to run 'make' from your dos prompt

Setting up JDK environment variables for Eclipse and Command line

I had Java working with Eclipse but I had to set up up Javac on the command line. I set the environment variables shown below but it doesn't work. Eclipse has now also stopped working.
Any help would be great!
Thanks!
Ok so I went a bit crazy and uninstalled/reinstalled loads of different jdk's. Finally one installed completely when I saved it directly to my C drive. I updated my environment variables for eclipse and for my command prompt and voila! Java is now working! I guess the problems with the space between Program Files will haunt me forever so I shouldn't save anything there anymore.

Run, The Command Line and that Path Variable

I'm having a very weird issue with the command line and running Ant. I point the path variable at the location of my Ant bin directory (C:\Ant\bin) and when i go into a command window and type PATH it shows the location in it. But when I go to run Ant by typing "ant" it does nothing and states that it isn't recognized. But when I go to the run window (Windows+R) and type "ant" it runs it.
I have restarted Windows twice and the problem still persists. I am running Windows Vista Ultimate with SP1 installed. I have tried "Running as Administrator" with no difference.
Any one experience anything like this before?
Sometimes you can set a system-wide (or even just personal) Environment Variable and it'll cure it, as opposed to just setting it in your shell.
Go to the Control-panel, then System, then Advanced, and look for the button on Environment Variables. From there, you can follow your nose.
Good luck.
Ant also depends on Java to be on the path. Do you have that?
I would also check to make sure the environment variables ANT_HOME and JAVA_HOME are set up properly in the console.
Is there any chance that the command window you are trying to run Ant in is a different window to the cmd windwo where you set up and verify that its in the path? If the PATH is updated after a cmd window is already open it won't recongnise the change. Not clear if that might be your issue.
If you are in the dir C:\Ant\bin and type "ant" does it recognise it?