This summer, I am a teaching assistant for a professor in a Python course. Last Wednesday, I explained to the students that they absolutely must use the IDE of the course, i.e. PyCharm. Otherwise, if a student is doing practical work using another IDE (e.g. VS Code), it is possible that the interpreter of PyCharm is different from that of the other IDE. This is WRONG!
The teacher explained to me that this is not the case. Students can use the IDE of their choice. This will have no impact when interpreting the code.
I don't know where I made the mistake. During an algorithmic course in C ++ at the last session, the teacher explained that we could not use any other IDE than the one in the course. If we decided to use a different IDE than the one in the course, then it was possible to have compilation conflicts.
Why in Python the choice of IDE does not matter, while in C++ it does?
I think you're actually mixing up two important things. The editor that is used to create the code can technically be anything. There are a number of nice-to-haves with editors that help you write code, such as auto-indentation, variable name expansion, etc. But many editors (e.g. IDEs) also have built in compilation and execution environments. This means particular versions of python (pycharm allows you to run things under multiple runtime environments, eg) or support for particular compilers (eg, for c++ it might be gcc-c++-10.3.1 or something).
What will make a difference is that the editor must support the code semantics required for the class for it to "help" you (type hints in python only exist after a certain point in the languages, as does lamba functions in c++).
But the reality is that you can write your code in notepad, and very basic tools. As long as you execute it in the environment that the teacher wants to grade things in to ensure everyone is using a standard execution framework to make his life easier, the editor shouldn't matter. But it is a lot easier for them to say "use this IDE, with this run time configuration" than explain all this to each student where some use vi and others emacs and others pycharm and others ...
An IDE is just a tool, used to simplify code writing, source control, debugging...
Like other tools, it's doesn't matter which IDE you use, the most important is which tool your know use and what are your ability to deal with this advantage and this inconvenient.
You can code in C++ with just a compiler, like g++, clang++ or msvc and text editor like emacs, notepad++, or vim for example. Just like in python you can code just with a python interpreter and a text editor.
This is mainly in reference to this answer in "Python vs Groovy vs Ruby?"
What makes Python and Ruby easier to develop outside an IDE?
The link also mentions debugging in the console. What is meant by that exactly?
Python and Ruby are easier to develop outside of an IDE than most of the JVM languages in general because they require less "overhead." I will speak primarily about Python, because that's my primary language.
In general, a Python installation has a single source for libraries (unless you're using virtualenv), and the whole project lives on the filesystem. There is no need to worry about .jar or .class files -- everything is compiled at runtime, and the .py files are your distributables.
Furthermore, Python is more concise than Java, and Groovy inherits a lot of Java's syntax (although it abstracts some things away). IDEs help to deal with boilerplate, making it less work for the programmer -- but languages without so much boilerplate don't require that help.
I disagree with the assertion that groovy is harder to develop with outside of an IDE. I've done serious python and groovy development, and a little bit of ruby, mostly without an IDE.
While there isn't a pdb style debugger, there's a console: groovysh is a non-GUI console, command line app, and groovyConsole is a GUI with simple syntax highlighting and editing. The rails and TDD philosophies emphasize development with tests rather than debuggers, and I find I rarely, if ever, feel the need to use a full-on debugger if I've got good test coverage. Whether this matters to you really depends on your own style of development.
Groovy simplifies the whole jar/classpath mess. While you can still set the classpath if you want, it's much easier to let groovy manage it entirely. Groovy automatically includes jars in $GROOVY_HOME/lib and ~/.groovy/lib in the classpath. Installing a library is simply copying it there. Better than that, with #Grab, you can declare your dependencies right at the top of your script, and groovy will automatically download the version you specify, and recursively get all of its dependencies and set up the proper classpath and classloaders; it can even manage two libraries that depend different versions of the same jar. Grails also has declarative dependencies.
The groovy language itself is just as concise and flexible as either ruby or python. While you can write it like full-blown Java, groovy can be written to look very similar to ruby.
One valid complaint against groovy vs python and ruby is that the startup time of the JVM is still noticeably worse.
Also for example Ruby on Rails includes some things that would otherwise be handled by IDEs like generators and console.
Could anyone tell me how to use pure Python without Cocoa support in Xcode? I can only find the Cocoa-Python template on the Internet.
Thanks in advance.
If you are just trying to write pure Python command line tools, using Xcode is like using a big sledge hammer to hit a tiny nail, in other words, probably not the best tool for the job. There are some old posts out there about how to set up a pure Python Xcode project, like this one, but, in the end, you might be better off using an editor you're already familiar with, like emacs, or, if you don't mind spending a little bit of money, TextMate, all along with a free vcs like mercurial or git. Or take a look in MacPorts for those and other options.
Just about the best IDE for editing and running Python code is actually still emacs. The python-mode for emacs does a wonderful job of maintaining whitespace and, with a bit of configuration, emacs is truly a powerful editor.
Pretty radically different than your typical GUI editor, certainly, and some find it quite distasteful. I've personally used emacs, mostly, for editing Python since 1992 or so.
Google will reveal all, including a native version of Emacs for Mac OS X.
A lot of people like eclipse with PyDev for python, although I don't know how wel it works on OS X with apple's mishandling of java.
Even though I am using BBEdit, I found Wingware Python editor did a good job in exploiting the introspected data of Python modules. Purely designed for Python. Give it a try.
http://www.wingide.com/
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 8 years ago.
Improve this question
I'm about to start a new job where the coding practices are heavily centered around TDD and refactoring, and whose primary development language is Python. I come from the Java world, and have been a confident user of Eclipse for a good, long time. When not working in Java, I use emacs.
I'm looking for an IDE for Python that will give me a lot of the capabilities I've grown used to with Eclipse, not only for refactoring but in terms of code completion, project management, SCM integration (currently CVS, but likely to switch to git one of these days) et al.
What IDE should I use?
My 2 pennies, check out PyCharm
http://www.jetbrains.com/pycharm/
(also multi-platform)
Have tried many different (Kate, Eclipse, Scite, Vim, Komodo): each one have some glitches, either limited functions, or slow and unresponsive. Final choice after many years: Emacs + ropemacs + flymake. Rope project file open dialog is extremely quick. Rope refactoring and code assist functions are super helpful. Flymake shows syntax mistakes. Emacs is the most configurable editor. I am very happy with this config. Python related part of config is here: public.halogen-dg.com browser/alex-emacs-settings/configs/cfg_python.el
I use TextMate for all my Python programming needs. It's not an IDE per se, but it does a lot of stuff that an IDE does (without all the cruft of an IDE). It has syntax highlighting, code folding, integration with various SCMs through the use of additional bundles (I know it supports SVN, Git, Mercurial, Darcs, and probably a few others). It's also quite extensible and customizable (again, through the use of bundles). It also has a basic concept of projects. One place where it doesn't shine, though, is in code completion; some bundles have limited support for code completion, but it's generally not as amazing as that of most language-specific IDEs. Given how awesome TextMate is, though, I don't know sacrificing that. TextMate's definitely made me much more productive.
Pydev for Eclipse, as others have mentioned, is good.
Netbeans has a beta Python plugin that is a little rough around the edges, but could turn into something really cool.
Additionally there is a long list of programming centric text editors for the mac, that may or may not fit your needs.
Textmate - costs money, people love this program, but I haven't used it enough to see what all the fuss is about.
Jedit - Java based text editor, has some nice features, but the startup time isn't great (due to Java).
CarbonEmacs - Decent Emacs port.
AquaEmacs - Better Emacs port.
TextWrangler - Lite, free (as in beer) verision of BBEdit.
BBEdit - The old guard. The defacto editor before Textmate stole its limelight. Expensive.
Smultron - Very nice editor, the UI is similar to Textmate.
Idle - Python's own little editor, has some nice features, but also some major problems. I've personally found it too unstable for my usage.
Sublime Text - This is really sweet text editor that has some surprisingly good Python support.
Pycharm - Another solid full on IDE for Python.
Eclipse with Pydev works best for me on any platform.
I really enjoy using PyCharm. http://www.jetbrains.com/pycharm/
macvim + pyflakes.vim
I like Spyder, it has many tools, such as profiling, intelligent indentation helper and a good autocompletion support
https://code.google.com/p/spyderlib/
I usually use either komodo edit or aquamacs with ropemacs. Although I should warn you, IDE features won't be what you're used to if you're coming from a Java or C# background. I personally find that powerful IDEs get in my way more than they help.
UPDATE: I should also point out that if you have the money Komodo IDE is worth it. It's the paid version of Komodo Edit.
If you have a budget for your IDE, you should give Wingware Professional a try, see wingware.com .
I've used WingIDE and have been very happy. Intellisense is pretty good, some other things are a bit wacky but overall it's a very productive tool
If you are looking for an interactive environment and not needing to code modules, I would suggest IPython. Though this is developed with scientists/statisticians in mind, it will run just as well without any of the scientific packages installed. The features are powerful, with code completion, integrated help, integrated debugging, etc., and it functions as a notebook with Markdown and MathJax integration. By far the best choice for those that need powerful features without wishing to load megabytes of GUI into RAM--since it is browser based, it is used in your always loaded chrome/safari instance. ;-)
Eclipse PyDev plugin.
http://pydev.sourceforge.net/
since you are familiar with Eclipse maybe you are interested in Pydev
Python support on netbeans is surprisingly good, and comes with most of the features you're looking for.
TextMate or Panic's Coda. NetBeans works very well, if you want a full-blown kitchen sink IDE.
"Which editor/IDE for ...?" is a longstanding way to start a "My dog is too prettier than yours!" slapfest. Nowadays most editors from vim upwards can be used, there are multiple good alternatives, and even IDEs that started as C or Java tools work pretty well with Python and other dynamic languages.
That said, having tried a bunch of IDEs (Eclipse, NetBeans, XCode, Komodo, PyCharm, ...), I am a fan of ActiveState's Komodo IDE. I use it on Mac OS X primarily, though I've used it for years on Windows as well. The one license follows you to any platform.
Komodo is well-integrated with popular ActiveState builds of the languages themselves (esp. for Windows), works well with the fabulous (and Pythonic) Mercurial change management system (among others), and has good-to-excellent abilities for core tasks like code editing, syntax coloring, code completion, real-time syntax checking, and visual debugging. It is a little weak when it comes to pre-integrated refactoring and code-check tools (e.g. rope, pylint), but it is extensible and has a good facility for integrating external and custom tools.
Some of the things I like about Komodo go beyond the write-run-debug loop. ActiveState has long supported the development community (e.g. with free language builds, package repositories, a recipes site, ...), since before dynamic languages were the trend. The base Komodo Edit editor is free and open source, an extension of Mozilla's Firefox technologies. And Komodo is multi-lingual. I never end up doing just Python, just Perl, or just whatever. Komodo works with the core language (Python, Perl, Ruby, PHP, JavaScript) alongside supporting languages (XML, XSLT, SQL, X/HTML, CSS), non-dynamic languages (Java, C, etc.), and helpers (Makefiles, INI and config files, shell scripts, custom little languages, etc.) Others can do that too, but Komodo puts them all in once place, ready to go. It's a Swiss Army Knife for dynamic languages. (This is contra PyCharm, e.g., which is great itself, but I'd need like a half-dozen of JetBrains' individual IDEs to cover all the things I do).
Komodo IDE is by no means perfect, and editors/IDEs are the ultimate YMMV choice. But I am regularly delighted to use it, and every year I re-up my support subscription quite happily. Indeed, I just remembered! That's coming up this month. Credit card: Out. I have no commercial connection to ActiveState--just a happy customer.
I've searched on Google for an app like this for a while, and I've found only options with heavy and ugly interfaces.
Then I opened Mac App Store and found CodeRunner. Very nice and clean interface. Support many languages like Python, Lua, Perl, Ruby, Javascript, etc. The price is U$10, but it's worth it!
I've been using an Evaluation copy of Sublime Text. What's good is it doesn't really expire.
It's been good so far and was really easy to get started with.
I may be a little late for this, but I would recommend Aptana Studio 3.x . Its a based on eclipse and has everything ready-to-go for python. It has very good support for DJango, HTML5 and JQuery. For me its a perfect web-development tool. I do HTML5 and Android development too, this way I do not need to keep switching different IDE's. It my all-in-one solution.
Note: you need a good amount of RAM for this to be snazzy !! 4+ GB is awesome !!
Visual Studio Code + Official Python Plugin
Here you see an overview of its current Python features:
https://code.visualstudio.com/docs/languages/python
Chocolat
http://chocolatapp.com
It's lightweight and offers Code Completion. Costs money.
EDIT:
Apparently Chocolat was an interesting option in 2013 but since then many others came up and development stalled. Nowadays I recommend Visual Studio Code + Python Plugin.
You might want to look into Eclim, an Eclipse server that allows you to use Eclipse functionality from within your favorite text editor. For python-related functionality, it uses Rope, PyFlakes, and PyLint under the hood.
I'm a complete newbie to Python. I've worked on PHP/JavaScript earlier but starting today I'm moving onto Python. I have no idea about the environment needed for it. I could use some suggestions on it for me to get started.
Under Unix, Emacs is a good choice, to which I always come back, because it is convenient to have a single editor for everything, and because it's open source.
What is best for you depends on your past experience with IDEs. I'd say: stick with what you've been using, or take this opportunity to try an even better IDE.
Note: Python comes with Idle, which is a very simple (if limited) IDE.
Be sure to check out IPython. It's an enhanced interactive python shell with a bunch of useful features such as Tab-Completion using introspection (eg, type "my_object." to see a list of its attributes and methods), logging your interactive session to an executable python-file, defining macros, etc. The documentation page has a link to the tutorial as well as screencasts showing it in action.
On my mac/Linux machines, python came pre-installed. On windows I use both jython under the eclipse IDE and ActivePython with their IDE/eclipse. With eclipse you'll want PyDev.
It all depends on what you are looking for and what you are already using.
For instance, if you are using a more 'simple' editor at the moment: as long as it's got Python syntax you've got the basics.
If you are used to e.g. Eclipse you can just continue to use that, combined with Pydev. Besides syntax highlighting you'll also get more fancy features to help you debug and refactor your code.
Personally I use Emacs with python-mode (and a few other modes to interface with Subversion and Git). In the past I used Vim which also worked quite well.
My advice would be to start out with your current environment as long as it has some rudimentary support for Python. Once you are familiar with the language, start exploring what your environment is missing and either add it or if you cannot, switch to an enviroment which does support the feature.
I use gvim with some plugin in order to have better support for python.
If you like IDE, look at wing IDE wich is the best I have tested so far. Especially the debuger included is really helpful.
The Python Beginner's Guide and the official Python Tutorial both seem like good places to start.
Geany is a good option for a Linux setup, it's intellisense isn't that great but syntax highlighting is good and it can compile your code directly from inside the editor, plus it handles other languages such as C/C++, PHP, Java etc... Eric is another popular choice as it's a full IDE and I know some people use Eclipse.
On windows I use Notepad++, but it's mostly because I like text editors instead of fully blown IDE's.
Reference wise Daniel's choices are very good places to start, also check out Green Tea Press who do free computer books, there are two Python choices on there but the "Python for Software Design" book hasn't yet been published properly although you can download the manuscript. The "How to Think Like a Computer Scientist" book is a good one and not as scary as it sounds.
IDLE is nice to try out things. Other tools that people like are Eclipse with the Pydev plugin which seems to work ok, although it has crashed a few times (Eclipse, that is) and NetBeans (which I haven't tried) but some people seem to like.
I can only help you if you're running a Mac. Download Xcode. I believe that Python 2.3 comes bundled with these development tools. Luckily enough, this is all you really need to get started, unless you want a newer version of Python.
All you need to do is open up Terminal and type python. You're done!